PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

Can forms be pre-filling in with information from a POST request?

  1. Shauny
    Member

    I have a custom form built on my site but we now need PayPal payments added to the form, so I am going to try Gravity Forms but before I do I need to know if this will work.

    The visitor browses the site and clicks an event he wishes to book. This sends him to a form with a POST request filling in the details of the event he clicked. He then fills in the form and sends it.

    Will I be able to keep this functionality with Gravity Forms?

    Note that the pre-filled in stuff is not in a form field, it is in a box on the side and shown with PHP. I have a screenshot of what I mean here: http://imgur.com/EhBaF

    Thanks,
    Shaun

    Posted 12 years ago on Thursday November 24, 2011 | Permalink
  2. There's no built in way to populate a form using a POST. It's very easy to populate fields in the form using a GET (query string) but dynamic population via POST is not built in.

    There are hooks available to pre-populate values. You could parse the $_POST and then populate the values in your form before displaying it, but it would require some PHP code in your theme's functions.php file.

    There might be another way to do it as well. Here are the ways you can pre-populate the fields in a form using built in functionality:

    http://www.gravityhelp.com/documentation/page/Using_Dynamic_Population

    Please see if something sounds like it will work for you before you make a purchase. Feel free to ask more questions as well.

    Posted 12 years ago on Thursday November 24, 2011 | Permalink