+ Reply to Thread
Page 1 of 2 1 2 LastLast
Results 1 to 10 of 14

Thread: Address Bar URL Tracking in Form?

  1. #1
    Join Date
    Mar 2007
    Posts
    26

    Question Address Bar URL Tracking in Form?

    Is there a way to grab the actual URL that is displayed in the Browser address bar and pass it thru in form results? I don't mean the hidden field actual 'camefrom' code, but the actual address in the address bar in the browser window.

    Why? Sometimes i will do a sponsored page like for example, let's say i have a page called www.mysite.com/signup.html but the actual URL if clicked from a PPC ad would look like this... www.mysite.com/signup.html?source=googleppc and in that case i'd like to record the actual URL in the address bar to grab the source data and send it thru in form results so that I know it came from a paid google ppc click.

    I know this is getting a little into click tracking etc, but i was wondering if there is a code i can customize into the form to grab the URL shown in actual address bar?

  2. #2
    Join Date
    Mar 2004
    Posts
    2,224

    Default Re: Address Bar URL Tracking in Form?

    yep.

    change ur page to being PHP, then use $_GET["source"] to add the value 2 whatever fields u want

    i luv PHP (and formmail too!)

    get a book or hire a programer if u need to (its a real quick job)

  3. #3
    Join Date
    Mar 2007
    Posts
    26

    Default Re: Address Bar URL Tracking in Form?

    Thanks for the tip, i'm a big PHP fan too, but some of my client sites have to remain HTML pages where the forms are (for various reasons). Is there anyway to do it with a HTML page, like a hidden field code that records the address bar or maybe a javascript?

  4. #4
    Join Date
    Mar 2004
    Posts
    2,224

    Default Re: Address Bar URL Tracking in Form?

    have to remain HTML pages where the forms are (for various reasons)
    i dont understand. php pages are html.

    i'd be interested to hear the reasons why u cant use php.

    yes, i think u can use javascript to get the url info.

  5. #5
    Join Date
    Mar 2007
    Posts
    26

    Default Re: Address Bar URL Tracking in Form?

    Well yes they are in a way, but i have to keep the form on a .html on the page for some clients (can't change the extension to .php). I have valid reasons for this, but won't get into them here.

    Can i use the $_GET["source"] in the actual formmail.php file or maybe a referrer command?
    Last edited by enicola; 26-Apr-2007 at 10:29 PM.

  6. #6
    Join Date
    Mar 2004
    Posts
    2,224

    Default Re: Address Bar URL Tracking in Form?

    too late once it gets to formmail

    u have to grab it on the page that has that url

  7. #7
    Join Date
    Mar 2007
    Posts
    26

    Default Re: Address Bar URL Tracking in Form?

    yes, that's what i figured, i'll see what i can do with a javascript.

  8. #8
    Join Date
    Mar 2007
    Posts
    26

    Talking Re: Address Bar URL Tracking in Form?

    Hooray! looks like i got the URL in address bar to show in the 'referring page' form results and it grabs the ?source= stuff.
    Now this shows in the formmail error page, how can i get that same data into the formmail results page (when there is no error and form processes ok)
    Last edited by enicola; 27-Apr-2007 at 03:10 AM.

  9. #9
    Join Date
    Mar 2007
    Posts
    26

    Wink Re: Address Bar URL Tracking in Form?

    ok, got it! Russell just told me to add hidden field for referrer like this (also shows ip and browser too).

    <input type="hidden" name="derive_fields" value="ipaddr = REMOTE_ADDR,
    browser = HTTP_USER_AGENT, referrer = HTTP_REFERER" />

    what's great about this is not only does it show the webpage address referred from, but it can also show the source of your PPC campaign click if you tweak your campaigns link a little (like google adwords) it can reveal it's source from google. To do this in Google PPC and others, just change your page URL on the ppc ad from www.yoursite.com/yourpage.html to www.yoursite.com/yourpage.html?source=googleppc and then when your visitors clicks from PPC to your form page, they fill out your form and you get the referrer page data in your email results showing it came in from a google click like this...

    ipaddr: xx.xx.xx.xx
    browser: Mozilla/5.0
    referrer: www.yoursite.com/yourpage.html?source=googleppc

    when a visitor uses that same page from an organic/natural search and fills in it would just show the normal url, like this...

    ipaddr: xx.xx.xx.xx
    browser: Mozilla/5.0
    referrer: www.yoursite.com/yourpage.html

    it's a good way to quickly know if you paid for the inquiry via PPC or not, of course i would still recommend using your ppc click tracking tools too, but this is very cool!
    Last edited by enicola; 27-Apr-2007 at 03:47 AM.

  10. #10
    Join Date
    Mar 2004
    Posts
    2,224

    Default Re: Address Bar URL Tracking in Form?

    of course!

    i sholud have thought of that, sorry.

    did u subscribe? i didnt see ur post on the subscription forum

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Similar Threads

  1. Using formmail from URL bar?
    By Eric Sandres in forum FormMail Subscription Support
    Replies: 1
    Last Post: 05-Nov-2004, 03:52 AM
  2. Now I am stomped! URL for redirect
    By sigurdur in forum FormMail Subscription Support
    Replies: 3
    Last Post: 01-Aug-2004, 01:02 AM
  3. Don't want to force entering an email address
    By Goji in forum FormMail Subscription Support
    Replies: 10
    Last Post: 22-Jun-2004, 02:54 AM
  4. Formmail File Visible In URL Address
    By amazing616 in forum FormMail Subscription Support
    Replies: 5
    Last Post: 03-Jun-2004, 09:13 PM
  5. The requested URL was not found on this server.
    By aussieincanada in forum FormMail Subscription Support
    Replies: 1
    Last Post: 27-May-2004, 08:46 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts