$('#reg_submit').click(function () {
var reg_password1 = $('#reg_password1').val();
letters = /([a-z])([0-9])/;
var errorMessage = '';
if ( ! reg_password1.value.match(letters) )
{
errorMessage = "Password must be alphanumeric";
$('#msg_regpass1').html(errorMessage).show();
}
else {
$('#msg_regpass1').html('').hide();
}
});
i used the above jquery code for applying alphanumeric validation to my registration page.but i am getting the javascript error related to match(), something match is undefined like that. can anyone suggest the solution for the above problem or please provide some other code for getting alphanumeric validation for above code. that letters pattern also not working properly for alphanumeric validation.can anyone suggest other pattern
thanks in advance