1.

Solve : Javascript "Permission denied" with Arrays and match??

Answer»

It errors me, "Permission denied"

Code: [Select]var found = false;
var WII = new Array(30)
WII[0]='/';
WII[1]='-';
WII[2]='_';
WII[3]='(';
WII[4]=')';
WII[5]='*';
WII[6]='&';
WII[7]='^';
WII[8]='%';
WII[9]='$';
WII[10]='#';
WII[11]='';
WII[12]='!';
WII[13]='+';
WII[14]='=';
WII[15]='[';
WII[16]=']';
WII[17]='{';
WII[18]='}';
WII[19]='|';
WII[20]=':';
WII[21]=';';
WII[22]='"';
WII[23]="'";
WII[24]='>';
WII[25]='.';
WII[26]='<';
WII[27]=',';
WII[28]='/';
WII[29]='?';
 
for(var xx=0;xx<=30;xx++) {
if(document.write(obj.value.match(WII[xx]))) {
found = true;
}
}
Don't know if this will help,

but the for loop is executing one too many times.

try this

Code: [Select]for(xx=0; xx < 30; xx++) {
I'll try and help if that doesn't work.



Discussion

No Comment Found