Change text of submit button conditionnally

  • Triacees
    Asked on April 14, 2016 at 1:21 PM

    Hi, 

    I wonder if it's possible to change the submit-button-text based on a certain condition.

    Hiding or showing with a condition is a piece of cake, but changing the text: I shouldn't know.

     

    Any idea?

     

    Grtz,

    Cees

  • Huberson
    Replied on April 14, 2016 at 2:43 PM

    No, it is not possible to modify the submit button text with conditions.

    If what you need is to show a different submit button you can add more than one and show the appropriate one with conditional. Although this will have no effect but visual.

    Hope that answers your concern.

  • Triacees
    Replied on April 15, 2016 at 4:40 AM

    I already did that: making a different submit button to show on a certain condition. This worked well until I inserted the 'Preview before submit' widget. The 2nd submit button has disappeared from the actual form. 

  • Elton Support Team Lead
    Replied on April 15, 2016 at 6:35 AM

    It is because the preview before submit widget removes all the submit button and replace it with a preview button.

    You can inject the following CSS codes to show the 2nd button but you cannot hide it using condition anymore.

    button#input_36 {

        display: block !important;

    }

    button#input_36 + button {

        display: none;

    }

    Guide: https://www.jotform.com/help/117-How-to-Inject-Custom-CSS-Codes

    Here's how it works:

    Change text of submit button conditionnally Image 1 Screenshot 20

    If you want all the submit buttons to appear without using CSS codes, then you may consider removing the preview submit button widget.

    Thanks!