Hi, using a snippet I found on here I have this code:
var password;
var pass1="PASSWORD-HERE";
password=prompt('Whats The Magic Word?',' ');
if (password==pass1) alert('That Is Correct!');
else {
window.location="SITE-LINK";
}
But I want to make pass1 harder to see so I want to encrypt it and use that as the var. Then I want to decrypt it at the if so that it is harder to be used to access secure information. How would I go about doing this?