Solved

Parsing Search Engine Keywords From Referral URL

Posted on 2004-08-25
3
394 Views
Last Modified: 2012-05-05
Hello,

Does anyone know of any ASP.NET specific information on parsing the key terms from a referral URL for all the major search engines? Trying to display targeted ads dynamically based on the referral URL and am having difficulty finding resources on the subject that aren't years old and written in PHP or Perl.

Thanks
0
Comment
Question by:mskibbz
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 17

Accepted Solution

by:
AerosSaga earned 500 total points
ID: 11891327
Just find the characters used to delimit the keywords and write a little parsing routine, you can use the php or pearl ones as examples or to find the delimitation characters.  Heres a little example of how to parse for delimited character pattern:

HttpContext.Current.User = New GenericPrincipal(User.Identity, Split(authTicket.UserData, ","))

This splits comma seperated values, you should easily be able to adapt this and use something like this for additional referrer information.

Response.Write("<TABLE><pre>")
If Not Request.UrlReferrer Is Nothing Then
   Response.Write("<TR><TD>Referer</td><td>" & Request.UrlReferrer.ToString() & "</td></tr><pre>")
Else
   Response.Write("<TR><TD>Referer</td><td>blind (no referer)</td></tr><pre>")
End If

Response.Write("<TR><TD>User Agent</td><td>" & Request.UserAgent() & "</td></tr><pre>")
Response.Write("<TR><TD>Host Address</td><td>" & Request.UserHostAddress.ToString & "</td></tr><pre>")
Response.Write("<TR><TD>Host Name</td><td>" & Request.UserHostName & "</td></tr><pre>")
Response.Write("</TABLE>")

Regards,

Aeros
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article discusses the ASP.NET AJAX ModalPopupExtender control. In this article we will show how to use the ModalPopupExtender control, how to display/show/call the ASP.NET AJAX ModalPopupExtender control from javascript, how to show/display/cal…
Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question