Javascript password - check first letter only -
I need a login that only checks the first letter of a password and ignores anything behind it here my last The standard login-code received from the script. I know that this is not safe for web solutions:
var unArray = ["ExampleTom"]; // user for var pwArray = ["7 ******];"] / password (var i = 0; i & lt; unArray.length; i ++) {if ((un == unArray [ I]) & amp; amp; amp; (pw == pwArray [i])) {valid = true; The idea is that the user should write any number as a password, but if he starts with 7 then he succeeds ('7 * * * 'Only my thoughts have been written to clarify).
I do not know why you will do this, but here it is: var unArray = ["ExampleTom"]; // user var pwArray = ["7 ******];"] / password valid = for wrong (var i = 0; i & lt; unArray.length; i ++) {if ((pwArray [ I] four axes (0) === pw.charAt (0)) & amp; (UN == unArray [i])) {valid = true; }}
Comments
Post a Comment