Question: **PHP** Create a User Authentication page using the filename logon.php in a folder. I have attached the credentials.db file to test against the page. Please
**PHP** Create a User Authentication page using the filename logon.php in a folder. I have attached the credentials.db file to test against the page. Please submit a php file.
o The logon.php page consists of three (3) functions: authenticateUser($username, $password) displayLoginForm($message="") processPageRequest()
o The first statement on the page must be processPageRequest(); // Call the processPageRequest() function
authenticateUser($username, $password) function o Test whether the user entered valid login credentials Read the data values from the credentials.db file The data values include the username, password, display name, and email address The data values are separated by commas Convert the data values obtained from the credentials.db file into an array containing the four (4) values Compare the username and password values obtained from the credentials.db file to the values stored in the $username and $password variables If the strings match, Create a session Store the display name and email address values obtained from the credentials.db file in the session Redirect the browser to the index.php page If the strings do not match, Create an appropriate error message Call the displayLoginForm($message="") function Pass the error message
displayLoginForm($message="") function o Display the login form using the appropriate HTML statements Give the page a descriptive title Display myMovies Xpress! in some fashion (header text, picture, etc.) near the top of the page Provide directions to the user (in plain text) Create a form that includes the following controls: Note: Use the form tag
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
