by Enjoii on Mon Apr 07, 2008 1:12 am
Nevermind I have figured out how to do it by using char... I remembered the function after another language. Heres the code for anyone who needs it:
- Code: Select all
function doesContainLowerCase(data){ // chars: 97-to-122
var found;
for(d=0;d<data.length;d++){
for(i=97;i<122;i++){
charToChk = String.fromCharCode(i);
if(data.charAt(d)==charToChk){found=1;break;}else{found=0;}
}
if(found==1){break;}
}
return found;
}
function doesContainUpperCase(data){ // chars: 65-to-90
var found;
for(d=0;d<data.length;d++){
for(i=65;i<90;i++){
charToChk = String.fromCharCode(i);
if(data.charAt(d)==charToChk){found=1;break;}else{found=0;}
}
if(found==1){break;}
}
return found;
}