What is JotForm?
JotForm is a free online form builder which helps you create online forms without writing a single line of code. No sign-up required.

At JotForm, we want to make sure that you’re getting the online form builder help that you need. Our friendly customer support team is available 24/7.

We believe that if one user has a question, there could be more users who may have the same question. This is why many of our support forum threads are public and available to be searched and viewed. If you’d like help immediately, feel free to search for a similar question, or submit your question or concern.

  • Profile Image

    Dynamically Populate Form

    Asked by hosker4u on July 22, 2011 at 09:59 AM

    I am aware you can populate fields with the iFrame url - but I am wanting to provide people a simple javascript snippint.

    It needs to be dynamicly populated so I can give people a "refferal id" in the javascript code to populate the field

    I hope you can help. I have tried the code bellow without success:


  • Profile Image

    Answered by hosker4u on July 22, 2011 at 10:03 AM

    I also dont want to give them the full "source code" javascript as that is very messy, and want to ensure I can update the form easily.

  • Profile Image

    Answered by hosker4u on July 22, 2011 at 01:19 PM

    I have a PHP solution that replaces some of your javascript with mine.


    It detects input_49 with a value of 0 and sets it with a javascript variable I can change elsewhere.


    Is their a proper solution, rather than my hack.

  • Profile Image
    JotForm Support

    Answered by NeilVicente on July 22, 2011 at 04:04 PM


    I believe this question is related to your comment in the user guide - How to Use a Single Form in Multiple-Sites and Know Which Site a Submission CameFrom

    Please click here to read my response to your comment. Let me know if it helps or not. If your question in this thread is not related to that comment, feel free to contact us again.

    Our support team are very eager in helping our users make the most out of Jotform. We will be looking forward to your response and queries. Thank you and have a great day!