Is there any other way I can retrieve GET parameters from the URL?

  • sarveshshukla075
    Asked on May 9, 2025 at 5:07 AM

    Is there any other way I can retrieve GET parameters from the URL? For example, something like:

    http://localhost/test/newtest.php?accountype={accountype}

    I’m looking for a way to access the value of "accountype" dynamically. Let me know if there’s an alternative method or best practice for this.

    Regards,

    Sarvesh

  • Jefferson JotForm Support
    Replied on May 9, 2025 at 5:27 AM

    Hi Sarvesh,

    Unfortunately, it's not possible to directly retrieve or process GET parameters using PHP or JavaScript, since Jotform doesn't support running custom scripts. However, Jotform does support URL prefill, which allows you to pass values from the URL directly into specific form fields. For example, if your form field's Unique Name is accountype, you can prefill it using a URL like this:

    https://form.jotform.com/yourFormID?accountype=admin

    This will automatically populate the accountype field with the value admin when the form loads. Just make sure:

    • The target field is a compatible type (e.g., Short Text, Dropdown)
    • The GET parameter name matches the field’s Unique Name (not the label)
    • You test the link in a real browser tab, not the Form Builder preview

    This is the only supported method for retrieving GET parameters in Jotform. Let us know your use case, and we can help you set up the right prefill structure. We also have a guide about Prepopulating Form Fields via URL Parameters that you can check out.

    Let us know if there’s anything else we can help you with. 

Your Answer