How to prepopulate full name field?

  • sandboxlogistics
    Asked on June 1, 2017 at 12:57 AM

    One thing I've noticed is if for example I have a full name (i.e.. bla_name[first] and bla_name[last]) that I cannot pull the field values separately when generating the form url on a save submission because the variable name is actually {name} and it has the full name .. therefore a link like ?name[first]={name}&name[last]={name} would pre-populate both fields with the full name... You would think this would work but it doesn't:

    ?name[first]={name[first]}&name[last]={name[last]}

  • Ashwin JotForm Support
    Replied on June 1, 2017 at 1:45 AM

    Hello,

    I'm sorry for the trouble caused to you. The correct format to populate the first name & last name fields should be:

    ?name[first]={fieldname:first}&name[last]={fieldname:last}

    Where "fieldname" is the name of your full name field of form which you are reading and "name" is the name of full name field which you want to prepopulate.

    For example:

    Please test the following demo form I created for you where I have set the custom thank you URL to redirect to same form and populate the name field: https://www.jotform.com/71481297354967 

    I have added the following prepopulation URL in the form:

    https://www.jotform.com/71481297354967?name[first]={name:first}&name[last]={name:last}

    Feel free to clone this form for a closer look. The following guide should help you in form cloning:  https://www.jotform.com/help/42-How-to-Clone-an-Existing-Form-from-a-URL

    Hope this helps.

    Do get back to us if you have any questions.

    Thank you!

  • sandboxlogistics
    Replied on June 7, 2017 at 2:44 PM

    Worked perfectly! thanks.