Page referral code does not work

  • Profile Image
    Giftsngadgets
    Asked on May 23, 2012 at 06:55 PM

    Hi, 

    I have tried to embed the script to know the URL from which page a form was completed  which i found here:

    http://www.jotform.com/help/95-How-to-Know-The-Exact-URL-Of-a-Page-Where-a-Form-Submission-Is-Made

     

    However: if i  embed the following code below, the referrer field is not completed (stays empty) on my form mail.

    Code: 

    <scripttype="text/javascript">

    document.write("<script type="text/javascript" src="//form.myjotform.com/jsform/21436945234555?referrer=" + window.location.href + "\"></" + "script>");

    </script>

     

    Besides this, on top of my form it show a small piece of code : document.write("

    Anyone an idea what could be the problem? 

    Edwin 

  • Profile Image
    Mike_T
    Answered on May 23, 2012 at 07:41 PM

    Thank you for contacting us.

    There should be space between script and type "<script type".

    Please try with the following code:

    <script type="text/javascript">
    document.write("<scriptsrc=\"http://form.myjotform.com/jsform/21436945234555?referrer=" + window.location.href + "\"></" + "script>");
    </script>

    If you need any further assistance, please let us know.

  • Profile Image
    Giftsngadgets
    Answered on May 24, 2012 at 04:14 AM

    Worked like a charm!

    This solves a long standing problem for me!

    Thanks, you guys rock!