User Guide

Finding The HTTP Page From Which A Submission Came

Last Update: January 13, 2017

This guide is deprecated. We already have a widget that captures referrer URL/website address. It's very easy to use without a need of modifying your form source code. Get it here: http://widgets.jotform.com/widget/get_referrer

Let's say you have created a form and embedded it into several web pages. Is it possible to identify the page from which a particular submission originated? Absolutely!

Please follow these instructions carefully:

1) Open your form in the form builder
2) From the "Power Tools" accordion menu on the left, insert a hidden field (Hidden Box) into the form
3) Change the label of this newly inserted field to pageAddress and save the form
4) Copy the full source code of your form (Setup & Embed > Embed Form > Source)
5) There should be a line, similar to that below, right before the tag:



Note the value of the id on that line. (For this example it is input_5 but it may be different in your form.)

6) Paste the html source code of the form into your page and add the following lines right after the tag



NOTE: The ID in this script must match that noted in Step 5. In other words, if the line before the tag in your form's source is



you would need to change 'input_5' to 'input_7'.

An alternative method, using an iFrame

9 Comments...

  • saldellamonica

    You can set the vale of the hidden field using the onSubmit event of the form...

  • Paul

    Hi, quick question, can this be done with a lightbox??

    Thanks in advance

    Paul.

  • madmax1930

    What if the form is being used in a Facebook fan page?

  • rabelardo

    good day.

    let's say i have the same id, where do i insert the sample script:


    document.getElementById('input_5').value=location.href;


    if i use the embed source code for joomla; such as this:



    thanks.

  • AndrewDavies

    This is very useful information indeed. Thanks for posting it.

  • MuhammadEid

    i want to know how to know from my visitor come thanks

  • stanccone

    Please help me with that...i try in diferent way but still nothing.
    I use Wordpress...
    How can I receive in my emails the page from where the form was sent?

    Thanks in advance!

  • bhpinfo

    I am still struggling with this one. Other methods, using embed code don't work for me, so I gave this method a go.

    It saved the form fine for a change, but it lost all of the nice formatting and converted it to plain bulleted list etc.

    How do I fix that?

  • richsmithphoto

    Can this technique be used with the Wordpress plugin? That's the only way I can get the forms to work. It seems to strip out scripts.

Send Comment