Solved

Parsing Search Engine Keywords From Referral URL

Posted on 2004-08-25
3
396 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

Technology Partners: 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

IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
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 …
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
In this video you will find out how to export Office 365 mailboxes using the built in eDiscovery tool. Bear in mind that although this method might be useful in some cases, using PST files as Office 365 backup is troublesome in a long run (more on t…

623 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