I have a form generator that uses (perl compatible) regexes for ther backend validation. Since the whole form is being dynamically generated it was fairly trivial to add a bit of jquery and then use the same regexes to validate on the client side pre submission.
However, some of the time the regexes don't behave themselves in Javascript, I am suspecting that either they are not being properly escaped, or contain illegal characters etc. Anyone knows a way of making sure that the same regex will work on both platforms?