Send to a Friend

Anaphase's avatar

Does Javascript support conditional if/then regular expressions?

Asked by Anaphase (768points) August 14th, 2008

I’ve been trying to find an article about this, but all my searches were futile. I usually try to not bog Fluther down with questions if I can find the answer by searching, but this is a rare case. Anyway, I want to know because I’ve been trying to write a regular expression with an if/then/else conditional in it, and Javascript is throwing errors at me left and right. I’m not sure if I’m just doing it wrong or if Javascript doesn’t support if/thens in regular expressions.

Any help would be appreciated.

Using Fluther

or

Using Email

Separate multiple emails with commas.
We’ll only use these emails for this message.