Phone Validate in js
function validatephone(xxxxx) { var maintainplus = ''; var numval = xxxxx.value if ( numval.charAt(0)=='+' ){ var maintainplus = '+';} curphonevar = numval.replace(/[\\A-Za-z!"£$%^&*+_={};:'@#~,¦\/<>?|`¬\]\[]/g,''); xxxxx.value = maintainplus + curphonevar; var maintainplus = ''; xxxxx.focus; }
0 comments:
Post a Comment