cancel
Showing results for 
Search instead for 
Did you mean: 

Form - Regular Expression Input Validation Message

vervinckt_joyca
Active Contributor
0 Kudos
161

Hi,

We built a Form in SAP Marketing Cloud, and wanted to apply extra validation to First Name, that it should have at least 2 letters.

We used the box "Regular Expression" for it with ^[a-zA-A]{2,}$

Technically this works fine, however when we try to submit the form with a first name with one single character, a validation message shows "The input must match the specified regular expression ^[a-zA-A]{2,}$". Not a very nice User Experience of course, and meaningless to most people 🙂

On other fields with a standard validation such as email, there is a box for Input Validation Message, where the custom error message can be written.

However, on First Name, where I applied the RegEx, I cannot seem to find an Input Validation Message box ...

Is it not possible to overwrite that technical validation message when using RegEx?!

 

Kind regards,

Joyca Vervinckt

 

MarkusGrant
Active Participant

Hi Joyca,

We faced the same situation last year when the feature was introduced. 

https://influence.sap.com/sap/ino/#/idea/231967/?section=sectionComments

As a workaround we just edited the error message in the downloaded HTML code...of course that might not be an option especially if you are publishing the form and not downloading it and deploying it manually.

MarkusGrant_0-1725622557926.png

 

Kind Regards,

Markus

vervinckt_joyca
Active Contributor
0 Kudos

Thanks for your reply @MarkusGrant . Such a shame it was reported 1,5 year ago and nothing was done about it... did you ever make that second influence request that Sylvia asked for?

Unfortunately I cannot use your workaround, as we are using the Forms in a Landing page and publish it like that 😞 

Accepted Solutions (0)

Answers (1)

Answers (1)

MarkusGrant
Active Participant
0 Kudos

Unfortunately I don't think I ever got round to raising a new influence request 🙁 And now no new requests are accepted...