How to show some other value for a checkbox item in email notifications

  • Haberl
    Asked on March 16, 2017 at 7:31 AM

    Hi,

     

    can I send another notification for a checbock than the "option". My option is a whole frase like "I want to receive...and so on". But in the notification I only want "Recieve newsletter: yes/no". Is this possible?

     

    BR

    Sebastian

  • Boris
    Replied on March 16, 2017 at 10:52 AM

    Yes, this can be possible in several ways with a little help of some workarounds.

    In general, the easier method for most people would be to use another hidden form field, and filling its value with conditional logic:

    https://www.jotform.com/help/268-How-to-Insert-Text-or-Mathematical-Calculation-into-a-Field-Using-Conditional-Logic

    Then, you would simply make sure to include that hidden field inside your email notification / autoresponder, and remove the form field with the long text.

    While the above is generally easier for most people, a much simpler and more effective method that I would prefer is to use the shortened version of the text on your form directly:

    How to show some other value for a checkbox item in email notifications Image 1 Screenshot 50

    Then, we can simply use a short CSS hack to change the text on your form, so that the full version of the text appears when the form is viewed through a web browser:

    How to show some other value for a checkbox item in email notifications Image 2 Screenshot 61

    The email the user would receive would contain the short version of the text, the one that was entered through the Form Builder:

    How to show some other value for a checkbox item in email notifications Image 3 Screenshot 72

    If that is indeed what you wanted to achieve, you can achieve it by adding the following snippet of custom CSS into your form:

    #label_input_21_0 { font-size: 0; }
    #label_input_21_0:after { font-size: 14px; content: "Gerne erhalte ich Informationen über die Kugleralm in unregelmäßigen Abständen per E-Mail"; }

    CSS can be added by following this guide:

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

    If you wish to apply the same on some different form field, you would only need to get the proper ID of the label you wish to modify, and change the text marked in red. Finding out IDs of a field label is somewhat of an advanced option, but you can find it out by right-clicking on the element, and using your browser developer tools / Inspect Element:

    How to show some other value for a checkbox item in email notifications Image 4 Screenshot 83

    Please try out the solution recommended above, and let us know whether it works to your satisfaction.