altamirador
18 Aug 2009, 6:33 AM
Hi !
Once again, I need help from the community ! I have a form from which I wish to validate a captcha that I have created. I load the captcha image from php and this part works pretty well. At the same time it loads, I pass the captcha value in a cookie. This works well also.
But, here's what I'm trying to do: When I get the image refreshed, I get the cookie and change the regex value from he form's field:
var RegularExpression = new RegExp(readCookie('captcha')); // captcha value converted to regular expression
Ext.get('FCaptcha').regex = RegularExpression; // assign to field named FCaptchaThat does not generate any error however, the field does'nt validate ??
Any ideas ?:((
It's the part in blue I'm not so sure about !!!
Altamirador
Once again, I need help from the community ! I have a form from which I wish to validate a captcha that I have created. I load the captcha image from php and this part works pretty well. At the same time it loads, I pass the captcha value in a cookie. This works well also.
But, here's what I'm trying to do: When I get the image refreshed, I get the cookie and change the regex value from he form's field:
var RegularExpression = new RegExp(readCookie('captcha')); // captcha value converted to regular expression
Ext.get('FCaptcha').regex = RegularExpression; // assign to field named FCaptchaThat does not generate any error however, the field does'nt validate ??
Any ideas ?:((
It's the part in blue I'm not so sure about !!!
Altamirador