Advertisement
Guest User

Untitled

a guest
Mar 18th, 2019
300
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.99 KB | None | 0 0
  1. ### 07.3 Compound Conditionals: ScriptEd Social Club
  2.  
  3. You are creating a new Social Club exclusive for ScriptEd students! But first, you must create a login form so only ScriptEd students who know the username and password will be able to login...
  4.  
  5. 1. Set the correct username and password in the `correctUsername` and `correctPassword` variables.
  6.  
  7. 2. Inside the click handlers you must use compound conditional statements to check for the following:
  8.  
  9. * If the username **AND** password is correct, display a success message in the div with the class `message`.
  10.  
  11. * If the username **OR** password is incorrect, display a message stating so in the div with the class `message`.
  12.  
  13. * If the username **OR** password fields are empty, display a message saying they should try entering something in the div with the class `message`.
  14.  
  15.  
  16. #### Done early?
  17.  
  18. Create additional compound conditionals:
  19.  
  20. 1. If the username is correct but the password is incorrect.
  21.  
  22. 2. If the password is correct but the username is incorrect.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement