View Full Version : vtypes password-confirmation

9 Nov 2009, 10:51 PM

A user should be able to enter a section, by using a password. When he save his password, he have to enter it a second time (for confirmation). Looks something like this:

password: __________________________________________
password confirmation: _______________________________

So far, I created a new vtype 'password':

Ext.apply(Ext.form.VTypes, {
password : function(val, field) {
if (field.initialPassField) {
var pwd = Ext.getCmp(field.initialPassField);
return (val == pwd.getValue());
return true;
passwordText : 'no match!'

My issue now is, that the user have to enter the confirmation

allowBlank : false
but always, when I load the form, I got after loading in the confirmation field, "This field is required!". I also set password and username allowBlank:false, but ther I have no problem.