Felitaur Site
Offerings
|
   
|
[Webscripting Homepage] | [Javascript Homepage] | [Perl/CGI HomePage] | [PHP Homepage]
PHP Program Assignment 4
For your second programming assignment, you will create one file.
prog4mysql.php
- Using mysqlcp.php and mysqltest.sql Do the following:
- Create the 3 tables in your own database, and get mysqlcp.php working on you account (20pts)
- Remove all of the functions from mysqlcp.php and put them in their own include files (30pts)
- Create form.php.inc file that generates the form (20pts)
- Make a seperate "Cleaner Class" that uses the following as appropriate:
- trim
- substr, str_replace
- strlen
- preg_match, preg_replace
- striptags (with any exceptions you feel appropriate
- htmlentities for printing (unless you wish to ALLOW some tags)
- Make a testclean.php to test this class out (60pts total)
- Create a mysql connection/error class file called mydb.php.inc and a mydbtest.php(80pts)
- class file should get username and password from outside the public_html directory
(possibly even using it as a function call argument instead of hard coded)
- Should allow the passing of database names, queries and so on into and out of class.
- Should be able to return values to database object created
- update from the mysql to mysqli functions
- In addition to the "view auctions" and "add auctions" functions that will be moved to their own include files in step 2 above
(and cleaned up to use the mydb.php.inc class etc) you need to do the following:
Adding a User: Should store a md5 password in a table and do a password/username check) 30pts
- All of this should now be accessible from mysqlcp.php (50pts)
- Print
the date
at the bottom of the page in the format Monday, January 23, 2005
This page last updated on:
|
|