Question: Next, create a javascript file and name it login.js. Store this file in a js sub-directory. Link it to your login.html page. No surprises here.

Next, create a javascript file and name it login.js. Store this file in a js sub-directory. Link it to your login.html page. No surprises here. This script will be used to validate the users login credentials. Two people should be able to login, me as admin@titanmusicstore.com with the password "LogMeIn", and you with whatever username and password you want to create. So your login javascript code needs to validate either of those logins and redirect to a myaccount.html page( you will need to create this page as well. You don't need anything fancy in it.). If they are invalid, display an alert message that the password or username is incorrect try again. You can hardcode the admin password and name and your username and pwd for now until we get more in depth. The key to this assignment is understanding the action attribute of a form, understanding what return false and return true does, and using document.getElementById to retrieve user input.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!