diff --git a/examples/changepass.html b/examples/changepass.html index 097f777..6ea3b3c 100644 --- a/examples/changepass.html +++ b/examples/changepass.html @@ -18,6 +18,8 @@ function toHexString(byteArray){ }).join(''); } var password = prompt("Please enter the password"); +password = password.trim(); +password = encodeURIComponent(password); generateHash(password + location.hostname, 4).then(function(hash) { // million to one error. alert("hash value: "+hash) diff --git a/examples/index.html b/examples/index.html index d475e10..5519728 100644 --- a/examples/index.html +++ b/examples/index.html @@ -95,7 +95,7 @@