Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author codepeople

    (@codepeople)

    Hi,

    You simply should enter the URL to the new page, as the thank you page associated to the form (in the form’s settings), and then, in the thank you page it is possible to insert the shortcodes to use the data collected by the form. Please, visit the following links with additional information:

    https://cff.dwbooster.com/documentation#thanks-page

    https://cff.dwbooster.com/documentation#special-tags

    Best regards.

    Thread Starter Red Giraffe

    (@red-giraffe)

    thank you. This could work great – anyway to remove the <p> tags that wrap the result?

    Plugin Author codepeople

    (@codepeople)

    Hi,

    Please, insert the result between <pre> tags to prevent that WordPress includes the <p> tags in the result. For example:

    [CP_CALCULATED_FIELDS_RESULT]
    <pre><%fieldname1_label%>:<%fieldname1_value%></pre>
    [/CP_CALCULATED_FIELDS_RESULT]

    Best regards.

    Thread Starter Red Giraffe

    (@red-giraffe)

    Ah I can’t get that to work ?? Sure there’s no way to add the value on to an url? I’m trying to populate a payment form which would work perfectly if it could generate the url

    Thread Starter Red Giraffe

    (@red-giraffe)

    For example, is there no way instead of submit button I could have some html like:

    Click here to pay

    Plugin Author codepeople

    (@codepeople)

    Hi,

    If you want redirect the user to a specific URL passing the value of a variable as parameter, for example: https://www.yourdomain.com/?parameter=123, You can do it directly from an equation associated to a calculated field in the form. For example:

    (function(){
    document.location.href='https://www.yourdomain.com/?parameter='+fieldname1;
    })()

    or in the thank you page with the piece of code:

    [CP_CALCULATED_FIELDS_RESULT]
    <pre style="display:none;"><script>document.location.href="https://www.yourdomain.com/?parameter=<%fieldname1_value%>"</script></pre>
    [/CP_CALCULATED_FIELDS_RESULT]

    Of course, you should modify the previous code to use the correct fields names, URLs, etc.

    Best regards.

    Plugin Author codepeople

    (@codepeople)

    Hi,

    Another solution would be generate the link you are referring from an equation. For example, if you insert a “HTML Content” field in the form, with the following piece of code as its content:

    <div id="link_container"></div>

    Then, it is possible to generate the link into the “link_container” div from the equation, as follows:

    (function(){
    jQuery('#link_container').html('<a href="https://www.yourdomain.com/?parameter=fieldname1">Click here to pay</a>');
    })()

    Best regards.

    Thread Starter Red Giraffe

    (@red-giraffe)

    Oh my goodness that’s done the job perfectly! Thank you so much for this wonderful plugin ??

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘submit button generate dynamic link from calculated value’ is closed to new replies.