I am using ConfiForms and need to add a validation rule. When a user enter an email address that does not end with ".mil" I want the validation rule to display error message.
I need assistance building the regex to do this validation.
Thank you.
Add a validation rules that checks that in a condition
!*.mil
No need for the regular expression if you want to check only that the text ends with a .mil
Hi @Alex Medved _ConfiForms_ this works great but I need to make this part of a rule because it will need to work in conjuction with another check. See I have a checked ration button called DoD, so if the user select Yes for the DoD button then the email address MUST end with ".mil".
The code you gave me is great for the validation within the field definition, but when I add it to a rule it is not getting picked up, not sure what I am missing. Here is what I have so far
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Extend the condition to include the check for the radio button field
something like
Myradio:DOD AND !TestMil:.mil
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Alex Medved _ConfiForms_ following on this one, I have to add a second check, and it is failing. Does ConfiForms not like "OR"? see my code below:
Action:create AND RequestorDoD:Yes AND (!RequestorEmail:*.mil) OR (!RequestorEmail:*@nsa.gov)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
When this should trigger?
If I understand your intent right then it should be something like this
Action:create AND RequestorDoD:Yes AND !RequestorEmail:*.mil AND !RequestorEmail:*@nsa.gov
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
So, when the user tries to submit the form, if they are creating an account (Action:create) and they selected "yes" for DoD (RequestorDoD:Yes) then their email address must end with EITHER "*.mil" or "*@nsa.gov"
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.