WDV221

Create New User

User Email:

Password:

Instructions

  1. Create an email validation function that is triggered from the button click event and does the following:
    1. Gets the email address entered in the text box and performs a validation check for an "@"
    2. Gives an error message if the email is missing an "@". The message should be displayed in the errorMessage span.
    3. Sets a solid 2px red border around the userEmail text box
    4. Clears the errorMessage span and resets the border of userEmail if there are no errors. This should also happen when the reset button is pressed.
  2. Create a function called checkPasswordStrength that triggers on the keyUp of the userPassword text box.
    1. If the length of the password is less than 5 characters, display the word "Weak" in red in the passwordStrength span
    2. If the length of the password is greater than 5 characters but less than 10, display the word "Medium" in yellow in the passwordStrength span
    3. If the length of the password is greater than 10 characters, display the word "Strong" in green in the passwordStrength span

Back