by DaleP
5 replies
  • SEO
  • |
Hi there,

I have searched this forum high and low for this but didnt find what I was looking for.

All I want to do is capture the keyword that the user typed in Google to arrive at my landing page. I know there is a method where you can examine the query string.

Does google automatically hit my landing page with a predefined name/value pair such as kw={keyword}? or do I have to do something in order for google to post this variable to me.

I simply want to capture the keyword in my landing page and write it to the database.

Thanks!
#kwkeyword
  • Profile picture of the author gagan
    If I am getting it right, you can use something like statcounter to know your search keywords.
    {{ DiscussionBoard.errors[181031].message }}
    • Profile picture of the author DaleP
      Thanks but I want to know them in my landing page so I can do other things with them like write to my database ect.
      Signature

      \"Successful, happy and fulfilled people have three things in common: someone to love, something to do, and something to look forward to.\"

      {{ DiscussionBoard.errors[181045].message }}
      • Profile picture of the author DaleP
        Ok so it seems one is able to add a quierystring to your landing page URl like this...

        somedomain.com?kw={keyword}

        the thing is....if I have a few landing pages indexed by google alredy....how do I change the landing page URL and tack on this query string??
        Signature

        \"Successful, happy and fulfilled people have three things in common: someone to love, something to do, and something to look forward to.\"

        {{ DiscussionBoard.errors[181068].message }}
  • Profile picture of the author askloz
    you use the variable GET to extract it from the address bar and place the replaceable variable as a $variablename where you want the keyword in the address bar to appear.
    Signature
    {{ DiscussionBoard.errors[181147].message }}
    • Profile picture of the author DaleP
      thanks all, I ended up using the "HTTP_REFERER" server variable. It contains the full referrer address plus any keywords that the user typed which are passed in the referrer's querystring
      Signature

      \"Successful, happy and fulfilled people have three things in common: someone to love, something to do, and something to look forward to.\"

      {{ DiscussionBoard.errors[181250].message }}

Trending Topics