I have written a RegEx and trying to match if a input text match to it.

var inputtxt = document.fd.pwd;
var decimal=  /^(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[^a-zA-Z0-9])(?!.*\s).{8,20}$/; 

if(inputtxt.value.match(decimal))   
{   
    alert("Your Password confirms to New Password Rules.");  

}  
else  
{   
    alert("Your Password must contain atleast one each of following: \n\t 1 Uppercase alphabet \n\t 2 Lowercase alphabet \n\t 3 Digit[0-9] \n\t 4 Special Character[ie !,@,#,$ etc] \n\n It SHOULD NOT conatin any Blank spaces "); 

}

This code works perfectly in FF/CHrome/ IE8+ But doesn't work in IE6.

有帮助吗?

解决方案

Windows XP is the only Windows platform that still supports IE6. Support for Windows XP ends in... well, have a look for yourself here.

Global usage of IE6 is so low (outside of China) that it can be ignored without much side effects (kind of like all those low-usage browsers most people don't even know about).

In other words, the return on investment to support IE6 is way, way, WAY too bad to even think about doing it. Just drop the support and get on with your life, you'll save both time and money.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top