• Resolved Miawtwo

    (@miawtwo)


    I’m trying to connect wpforms with an api as in the link below.

    I need to insert shortcode in Settings/Confirmations/ by using Text method.

    Each time, WPForm add <p> </p> making my code as normal text, shortcode don’t working and makes it visible when form is submited.

    Is there an issue for ‘text’ stay text and / or short code and invisible ?

    Best regard.

    Benoit

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Support Ralden Souza

    (@rsouzaam)

    Hi @miawtwo,

    For this, you could disable the Visual/Text tabs using the code snippet below:

    /**
     * Disable auto-p in the Confirmation settings 
     *
    */
      
    function wpf_dev_builder_enqueues( $view ) {
              
        wp_add_inline_script(
            'wpforms-builder',
            'WPFormsBuilder.settings.tinymceDefaults = { forced_root_block : false, quicktags:{theme: \'modern\'} };'
        );
      
    }
    add_action( 'wpforms_builder_enqueues', 'wpf_dev_builder_enqueues', 10, 1 );

    Here’s a screenshot of the result: https://a.supportally.com/i/mZkc62.

    In case it helps, here’s our tutorial with the most common ways to add custom code like this. For the most beginner-friendly option in that tutorial, I’d recommend using the WPCode plugin.

    Hope this helps!

    Thread Starter Miawtwo

    (@miawtwo)

    Thank you very much for your answer and for taking an interest in my question !

    Your snippet is working perfectly but… The shortcode is still render as text and not as shortcode and is displayed after submitting the form instead to be invisible and send informations by the API…

    Here’s screenshots : https://monformateur.fr/tests/

    Plugin Support Ralden Souza

    (@rsouzaam)

    Hi @miawtwo,

    Thanks for letting me know!

    In this case, please try the code snippet available in our?guide on how to display shortcodes in confirmation messages. This may help to fire the result of the shortcode.

    In case the shortcode continues not working, I apologize as customizations like this are outside of our scope for support. In case you’d like to look into custom development options, we highly recommend using Codeable.

    Or you could try the Method 2 on https://wpgetapi.com/docs/using-with-wpforms/.

    Hope this helps!

    Hey @miawtwo – I’m Prashant filling in for Ralden.

    We haven’t heard back from you since the last message that my colleague sent, so I’m going to go ahead and close this thread for now. But if you’d like us to assist further, please feel welcome to continue the conversation.

    Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Shortcode in confirmations’ is closed to new replies.