Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Server Side: Write the code of the server side shopping.php page such that. 1) The shopping.php checks using the regular expressions in PHP if the
Server Side:
Write the code of the server side shopping.php page such that.
1) The shopping.php checks using the regular expressions in PHP if the login is valid or not. A valid login must be exactly 5 characters and starts with a letter and followed by any one or more of the characters:_, $, 0-9, A-Z, a-z For instance, a12341, ab_$$1, and abc0Z_ are valid logins
while _a1, b9993333*, and c23_@2 are invalid logins. But, there are no restrictions on the
password; the user can use any character in the keyboard.
2) The shopping.php page reads the login and passwords from a database named "customers" to verify whether the customer is a valid user. The "customers" database contains two tables named "login_pssword" and shopping cart. The login_pssword table has three fields customer_Id,"login" and"password, "credit balance". "credit balance" contains the remaining balance in the credit card. Initially, the "credit balance" for every 1000 USD.
Check if the user name and passwords exist. If it exists print the message "Thank you for logging in" and show him/her the products to start choosing. If the password or login is not in the database, display the alert message "wrong password and/or login please try again" and do not show him/her the products. The shopping_cart table has 3 fields: product_Id, product_name, product_price,
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started