Quform v2 version for iphorm_get_form

Home Forums Quform WordPress Quform v2 version for iphorm_get_form

This topic is: not resolved
Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #33674
    jerkski
    Participant

    Hello, I am having trouble migrating some old code from v1. Is there a compatible function in v2 for iphorm_get_form?

    #33679
    jerkski
    Participant

    For example, we previously used $form = iphorm_get_form(2); to access the labels and values in PHP from form with ID 2. How can this be done in Quform v2?

    • This reply was modified 3 years ago by jerkski.
    • This reply was modified 3 years ago by jerkski.
    #33683
    jerkski
    Participant

    The function used to exist in iphorm-form-builder/includes/common.php, but I do not see a comparable function in Quform v2. Any hints?

    #33687
    Ally
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

    #33696
    jerkski
    Participant

    Hi Ally, I did check out this function, but something is different. When used, it wants to load all entries (1000’s of entries) under form 2. The previous function used to only load the most recently submitted order from the form.

    Am I using the correct function for this? This is what I am trying to achieve, but in Quform v2: https://support.themecatcher.net/forums/topic/use-code-from-html-email-in-a-confirmation-page

    What I had done in the past was use $form = iphorm_get_form(2) in a php/html template that loaded immediately after the form was submitted. That template used iphorm_get_form(2) to display the previously submitted form entry’s labels and values.

    For example, here is what I tried:

    $repository = quform('repository');
    $factory = quform('formFactory');
    $config = $repository->getConfig(2);
    if (is_array($config)) {
        $form = $factory->create($config);
        print_r($form);
    }
    • This reply was modified 3 years ago by jerkski.
    • This reply was modified 3 years ago by jerkski.
    • This reply was modified 3 years ago by jerkski.
    • This reply was modified 3 years ago by jerkski.
    #33707
    Ally
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

    #33715
    jerkski
    Participant

    Hi Ally, we had emailed you the code for review. Thank you!

Viewing 7 posts - 1 through 7 (of 7 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