Buy Now
Sign in

How to accept "accent" with javascript validation of the form

bdernier , August 02 2016
B
bdernier
Hello,

I use Chronoform for years now and I am very pleased to use it. I am french and obviously accents are part of my language. Any time I upload a new version of Chronoform the first step I do is to modify the gvalidation.js file to allow accent into fields.

So I modify the file as below :

Before :
    alpha : /^[a-z ._-]+$/i,
    alphanum : /^[a-z0-9 ._-]+$/i,
After :

    alpha : /^[a-zA-ZáàâäãåçéèêëíìîïñóòôöõúùûüýÿæœÁÀÂÄÃÅÇÉÈÊËÍÌÎÏÑÓÒÔÖÕÚÙÛÜÝŸÆŒ ._\-\'\"\&]+$/i,
    alphanum : /^[a-zA-ZáàâäãåçéèêëíìîïñóòôöõúùûüýÿæœÁÀÂÄÃÅÇÉÈÊËÍÌÎÏÑÓÒÔÖÕÚÙÛÜÝŸÆŒ0-9 ._\-\'\"\&]+$/i,

Would be great if you could include this modification into the futur releases. I guess I am not the only one that could have this need.

By the way keep the good job up !

Best regards
Bruno