M
Maik
Was mir gerade noch aufgefallen ist: du bist nachlässig mit der Verwendung von Semikolons. Setz die mal bitte noch an den entsprechenden Stellen.
*lol*Am besten den Quellcode hier kontrollieren lassen.
http://www.jslint.com/ hat gesagt.:Error:
Problem at line 4 character 30: Missing semicolon.
show += password.length * 4
Problem at line 5 character 71: Missing semicolon.
show += ( checkRepetition(1,password).length - password.length ) * 1
Problem at line 6 character 71: Missing semicolon.
show += ( checkRepetition(2,password).length - password.length ) * 1
Problem at line 7 character 71: Missing semicolon.
show += ( checkRepetition(3,password).length - password.length ) * 1
Problem at line 8 character 71: Missing semicolon.
show += ( checkRepetition(4,password).length - password.length ) * 1
Problem at line 9 character 51: Expected '{' and instead saw 'show'.
if (password.match(/(.*[0-9].*[0-9].*[0-9])/)) show += 5
Problem at line 9 character 60: Missing semicolon.
if (password.match(/(.*[0-9].*[0-9].*[0-9])/)) show += 5
Problem at line 10 character 37: Unescaped '^'.
if (password.match(/(.*[!,@,#,$,%,^,&,*,?,_,~].*[!,@,#,$,%,^,&,*,?,_,~])/))...
Problem at line 10 character 62: Unescaped '^'.
if (password.match(/(.*[!,@,#,$,%,^,&,*,?,_,~].*[!,@,#,$,%,^,&,*,?,_,~])/))...
Problem at line 10 character 79: Expected '{' and instead saw 'show'.
if (password.match(/(.*[!,@,#,$,%,^,&,*,?,_,~].*[!,@,#,$,%,^,&,*,?,_,~])/))...
Problem at line 10 character 88: Missing semicolon.
if (password.match(/(.*[!,@,#,$,%,^,&,*,?,_,~].*[!,@,#,$,%,^,&,*,?,_,~])/))...
Problem at line 11 character 57: Expected '{' and instead saw 'show'.
if (password.match(/([a-z].*[A-Z])|([A-Z].*[a-z])/)) show += 5
Problem at line 11 character 66: Missing semicolon.
if (password.match(/([a-z].*[A-Z])|([A-Z].*[a-z])/)) show += 5
Problem at line 12 character 67: Expected '{' and instead saw 'show'.
if (password.match(/([a-zA-Z])/) && password.match(/([0-9])/)) show += 10
Problem at line 12 character 77: Missing semicolon.
if (password.match(/([a-zA-Z])/) && password.match(/([0-9])/)) show += 10
Problem at line 13 character 35: Unescaped '^'.
if (password.match(/([!,@,#,$,%,^,&,*,?,_,~])/) && password.match(/([0-9])/...
Problem at line 13 character 82: Expected '{' and instead saw 'show'.
if (password.match(/([!,@,#,$,%,^,&,*,?,_,~])/) && password.match(/([0-9])/...
Problem at line 13 character 92: Missing semicolon.
if (password.match(/([!,@,#,$,%,^,&,*,?,_,~])/) && password.match(/([0-9])/...
Problem at line 14 character 35: Unescaped '^'.
if (password.match(/([!,@,#,$,%,^,&,*,?,_,~])/) && password.match(/([a-zA-Z...
Problem at line 14 character 85: Expected '{' and instead saw 'show'.
if (password.match(/([!,@,#,$,%,^,&,*,?,_,~])/) && password.match(/([a-zA-Z...
Problem at line 14 character 95: Missing semicolon.
if (password.match(/([!,@,#,$,%,^,&,*,?,_,~])/) && password.match(/([a-zA-Z...
Problem at line 15 character 61: Expected '{' and instead saw 'show'.
if (password.match(/^\w+$/) || password.match(/^\d+$/) ) show -= 10
Problem at line 15 character 71: Missing semicolon.
if (password.match(/^\w+$/) || password.match(/^\d+$/) ) show -= 10
Problem at line 29 character 25: 'checkRepetition' was used before it was defined.
function checkRepetition(pLen,str) {
Problem at line 30 character 11: Missing semicolon.
res = ""
Problem at line 32 character 22: Missing semicolon.
repeated=true
Problem at line 34 character 13: Expected '{' and instead saw 'repeated'.
repeated=repeated && (str.charAt(j+i)==str.charAt(j+i+pLen))
Problem at line 34 character 73: Missing semicolon.
repeated=repeated && (str.charAt(j+i)==str.charAt(j+i+pLen))
Problem at line 35 character 21: Expected '{' and instead saw 'repeated'.
if (j<pLen) repeated=false
Problem at line 35 character 35: Missing semicolon.
if (j<pLen) repeated=false
Problem at line 37 character 22: Missing semicolon.
i+=pLen-1
Problem at line 38 character 27: Missing semicolon.
repeated=false
Problem at line 41 character 31: Missing semicolon.
res+=str.charAt(i)
Problem at line 44 character 15: Missing semicolon.
return res
Implied global: password 3,4,5,6,7,8,9,10,11,12,13,14,15, breite 20,21,23,24,26, document 26, res 30,41,44, i 31,33,34,37,41, repeated 32,34,35,36,38, j 33,34,35
mfg Maik