Question: Design an e - commerce website that sells physical copies of old and new video games and allows users to download games to their PC
Design an ecommerce website that sells physical copies of old and new video games and allows users to download games to their PC Use HTML CSS and PHP to construct the website.
Note that the website will have two separate login and logout php files one for the user and another for the useradmin. The useradmin login will be located at the bottom right of the home page when clicked it will take the useradmin to a different page where the admin is able to see pending orders, inventory of both games and consoles, add to inventory, view order number this being the product name, number, and quantity, then if admin clicks invoice it will show relevant information such as billing address, order number and total price, a table chart that displays what is being shipped this being product Name, Number, Quantity, and price, and the subtotal, shipping and handling charge, and total price again. After that the useradmin will update the order status, when useradmin clicks updae status to shipped it will say update successful and will update the order detail table in the data base from pending to shipped, and will decrement how many items were ordered from game and console quantity.
user the following database SQL to program the website:
Create the Database
CREATE DATABASE OldNewGenGamingCenter;
Use the Database
USE OldNewGenGamingCenter;
Create Table for users
CREATE TABLE Users
UserID INT AUTOINCREMENT PRIMARY KEY,
Name VARCHAR NOT NULL UNIQUE,
Gender ENUMmfo
EmailAddress VARCHAR
UserPassword VARCHAR NOT NULL,
Address VARCHAR
PhoneNumber VARCHAR
ShippingAddress VARCHAR
CreditCardNumber VARCHAR
CreditCardExpirationDate DATE
;
CREATE TABLE Games
VideoGameID INT PRIMARY KEY,
VideoGameName VARCHAR
PictureLink VARCHAR;
Genre VARCHAR
EsrbRating VARCHAR
GameAge VARCHAR
Price DECIMAL
;
CREATE TABLE consoles
ConsoleID INT PRIMARY KEY,
ConsoleName VARCHAR
ConsoleAge VARCHAR
ConsolePrice DECIMAL
;
CREATE TABLE QuantityonHand
VideoGameID INT,
Quantity INT,
PRIMARY KEY VideoGameID
FOREIGN KEY VideoGameID REFERENCES GamesVideoGameID
;
CREATE TABLE Orders
OrderID INT AUTOINCREMENT PRIMARY KEY,
CustomerID INT,
TotalWeight DECIMAL
TotalPrice DECIMAL
ShippingCharge DECIMAL
Date DATE,
Status VARCHAR
FOREIGN KEY CustomerID REFERENCES Users UserID
;
CREATE TABLE OrderDetails
OrderID INT, VideoGameID INT, Quantity INT,
Price DECIMAL
PRIMARY KEY OrderID VideoGameID
FOREIGN KEY OrderID REFERENCES OrdersOrderID
FOREIGN KEY VideoGameID REFERENCES GamesVideoGameID
;
CREATE TABLE Inventory
VideoGameID INT PRIMARY KEY,
Name VARCHAR
Description VARCHAR
PartNumber INT,
QuantityOnHand INT,
FOREIGN KEY VideoGameID REFERENCES Games VideoGameID
;
CREATE TABLE ShippingHandlingCharges
WeightBracket INT PRIMARY KEY,
Charge DECIMAL
;
INSERT INTO gamesVideoGameIDVideoGameNamePictureLinkGenreEsrbRatingGameAgePrice VALUES
'Devil May Cry 'DevilMayCryjpg 'hack & slash and actionadventure', M Rating', y
'fate samurai remnant', 'FateSamuraiRemnant.jpeg', 'action RPG 'Teen Rating', y
'wii sports resort', 'WiiSportsResort.jpg 'sports simulation', Ey;
INSERT INTO consolesConsoleIDConsoleNameConsoleAgeConsolePrice VALUES
'Play Station y
'xbox series xy
'wii console', y;
INSERT INTO inventoryVideoGameIDNameDescriptionPartNumberQuantityOnHand VALUES
'Devil May Cry 'hack & slash and actionadventure',
'fate samurai remnant', 'action RPG
'wii sports resort', 'sports simulation', ;
INSERT INTO quantityonhandVideoGameIDQuantity VALUES
;
INSERT INTO shippinghandlingchargesWeightBracketCharge VALUES
;
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
