Moonsoft Software Solutions

Email validation

Started 20 Jul 2012 · 3 replies

  1. _MSTeam#
    Here is the solution to add an email validation to one of your form fields, which you have typed 'text'.

    Go to javascript events, and write this:

    getCBFormValue('x').addClass('validate-email');


    Where 'x' is the field ID (from fields and code tab).
  2. Moonsoft support
    I tried this and didn't have success. In my case the name of the field variable is email.

    Here's what I put in the Javascript events:

    getCBFormValue('email').addClass('validate-email');

    Did I miss something?
  3. _MSTeam#
    Hello,

    getCBFormValue('email').addClass('validate-email'); is not valid...

    Just change 'email' text by the id of this field. You can check the id of the field in 'fields and code' section, on the left side of the field.

    For example, if 'email' field has 5 as id, you should write:

    getCBFormValue('5').addClass('validate-email');

    Regards,
  4. Moonsoft support
    That worked. Thanks!

Still stuck?

Customers with an active license can open a support ticket.

Log in to open a ticket