Title: Working With PHP and MySQL
1Working With PHP and MySQL
How to change the existing E-commerce site to
your own.
- Summer 2004
- EGN 3935 Introduction to Web Technology
Security
2Agenda
- How to create your own copy of the ecommerce
example of chapter 25 - How to include your own figure
- How to add your own category
- How to add item to your category.
3Create copy of ecommerce example of chapter 25
- Start a Windows DOS prompt.
- Go to Start -- Run -- Type cmd in the Run
window. This will start a DOS prompt. - Map network drive to your group directories
- net use J \\131.91.82.95\e6 /usermdo
- Password
- net use K \\131.91.82.95\g6 /usermdo
- No password will be asked this time.
4- Copy all files and sub directories from the J\
to the K\ in your windows explorer windows.
5How to Include a GIF file
- We want to change the Book-O-Rama logo to our own
for example. - Have a look at the existing Book-O-Ram logo.
- Right click on the Book-O-Rama logo, go to
properties and note the file name that it links
to. - First create own simple Book-O-Rama gif file.
6Right Click here
Clink on Properties
7Name of the pointed to .gif file
8Create a .gif file
- Start -- Program -- Accessories -- Paint
- Decrease the size of the working area relative to
the size of the Original Book-O-Rama figure in
the website. - Save file as K\images\Book-O-Rama.gif. Replacing
the old one.
Reduce the area
9Replaced Figure
10- Include a new figure with new name.
- First search which files are using the figure
Book-O-Rama.gif. - Start -- Search -- For Files and Folder
- On the left side in the Containing Text field
enter Book-O-Rama.gif. - In the Look In field choose
- g6 on '131.91.82.95' (K)
- And press Search Now.
11Type your text
Choose location
12- Click on the output_fns.php file and edit line 33
approximately. - a.gif"
- me.gif
- This will now show your own logo instead of the
Book-O-Rama default logo.
13How to Add New Category
- 1- Through the admin login
- http//131.91.82.95/esp04/g6/login.php
- Username admin
- Password YourGroupPassword
- 2- Through direct manipulation of the database
table categories
14Before Adding to Category
15Adding new Category Directly to Database
Double Click to open the table
To add new record
New category Travel added
16After Adding to Category
The newly added Travel Category
17How to add item to your category
- 1- Through the admin login
- http//131.91.82.95/esp04/g6/login.php
- Username admin
- Password YourGroupPassword
- 2- Through direct manipulation of the database
table books
18Before Adding a book to Travel Category
Empty category of Travel
19Adding a Book to a Category
Double Click on books table
To add new record
Newly added book
Ties to Travel category
20After Adding a book to Travel Category
Newly added book to the Traverl category
21Questions ?