Hidden fields

Home Forums Quform WordPress Hidden fields

This topic is: resolved
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #20366
    digitalmedia
    Participant

    I’m creating a 2 part form. The first form the visitor fills out a field with their address and clicks start. This redirects them to another page with a second form where they add their name, email and phone number, etc.

    What I want to do is populate the second form with the address from the first field on the first page. Is their a way to do this? Can this be a hidden field that pulls the data from the address form?

    This is a sale funnel collection method for Realtors providing free home evaluations to potential sellers. Statically, when users only have to fill out one address field and then move to a second form to provide the rest of their contact data, the completion rate is more than triple vs. having all the fields on one page. So this is why it is on two separate pages.

    Suggestions? Thank you in advance.

    #20367
    digitalmedia
    Participant

    I found this code for Passing data from one form to another. However, $data = array_map(‘rawurlencode’, $data); seems to break the site. Any ideas?

    function my_form_redirect($url, $form)
    {
    $data = array(
    ‘Address’ => $form->getValue(‘iphorm_1_1’),

    $data = array_map(‘rawurlencode’, $data);

    $url = add_query_arg($data, ‘http://vbrn.ca/home-eval-part-2’);
    return $url;
    }
    add_action(‘iphorm_success_redirect_url_2’, ‘my_form_redirect’, 10, 2);

    #20372
    support
    Moderator

    Hi,

    You forgot to close the array() with ); after the ‘Address’ line (look at the example here). Also, are you sure you used the correct element ID ?

    Hope this helps,

    Félix

    • This reply was modified 7 years, 6 months ago by support.
    • This reply was modified 7 years, 6 months ago by support.
    #20378
    support
    Moderator

    Hi,

    You can also follow along this example which is using a custom database to store the data.

    Regards,

    Félix

    #20382
    digitalmedia
    Participant

    Thank you very much for your response, i do appreciate it. I got it working. Your Quform has to one of the best form plugins available. Thanks again for all your help!

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.
Be inspired. © 2024 ThemeCatcher Ltd. 20-22 Wenlock Road, London, England, N1 7GU | Company No. 08120384 | Built with React | Privacy Policy