regular expression validation

How do I make a field validation fail if the pattern of the regular expression matches?
(the opposite of what you normally would want)
Thanks,
April

I’m relatively sure that the regular expression engine is java.util.regex.

As for your particular question, you may be able to use a zero-width negative lookahead.

(?!/access/helpdesk/help).*

That should return false if “/access/helpdesk/help” is found.

I haven’t tested (sorry - buried in other stuff), but I think that’s the direction you want to take.

Thanks. That’s very helpful.

[QUOTE=vtdarrell;10032]I’m relatively sure that the regular expression engine is java.util.regex.

As for your particular question, you may be able to use a zero-width negative lookahead.

(?!/access/helpdesk/help).*

That should return false if “/access/helpdesk/help” is found.

I haven’t tested (sorry - buried in other stuff), but I think that’s the direction you want to take.[/QUOTE]

April,

Were you able to get this working? After reading this thread, I am trying to solve the exact same problem, and can’t seem to get reliable results. Are you using this validation on an EPHOX field? or just plain text?

Thanks,

-Jason

Haven’t gotten back to working on this yet. I am trying to do the validation on a plain text field, not ephox.

[QUOTE=jlloyd;10701]April,

Were you able to get this working? After reading this thread, I am trying to solve the exact same problem, and can’t seem to get reliable results. Are you using this validation on an EPHOX field? or just plain text?

Thanks,

-Jason[/QUOTE]