Created
May 25, 2017 07:24
-
-
Save HishamMubarak/a253b76cd948bc35ab08df3449867313 to your computer and use it in GitHub Desktop.
Password Reset Form
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
function confirm() { | |
var pass1 = document.getElementById("passOne").value; | |
var pass2 = document.getElementById("passTwo").value; | |
if (pass1 != pass2) { | |
document.getElementById("passOne").style.borderColor = "#E34234"; | |
document.getElementById("passTwo").style.borderColor = "#E34234"; | |
alert("Password Don't Match"); | |
} else { | |
alert("Passwords Match"); | |
} | |
} | |
</script> | |
<form action="/reset" method="POST"> | |
<input type="password" id="passOne" name="pass1" placeholder="Enter New Password"> | |
<input type="password" id="passTwo" name="pass2" placeholder="Confirm New Password"> | |
<input type="hidden" name="resetCode" value="<%= code %>" /> | |
<input type="submit" onclick="confirm()"> | |
</form> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment