CIS Assignment:
Four-page Web Site
Preliminary attempt (without self-assessment) due Thursday 2 December
Final submission due Monday 6 December
Objectives
...be able to use a simple text editor to create web pages using valid XHTML and CSS
...be able to save web pages to a web server and edit those pages both by logging in remotely and by using FTP
...be able to integrate PHP commands into HTML documents to produce web pages
...develop full familiarity with elements of HTML forms and ways to process forms using PHP
...understand and appropriately use general programming structures such as variables, arrays, conditionals, and loops
...appropriately use common PHP built-in functions
...become familiar with a wide variety of PHP built-in functions and be able to use reference materials to figure out how to use any specific built-in function
...compare different ways to structure databases and to store and retrieve information
...be able to invoke the MySQL interpreter and use it to create and modify database information
...integrate database content into web pages by using PHP database functions to interact with MySQL
...learn some strategies for debugging PHP scripts
Criteria
Assignment will be graded out of 50 points
- Successful creation of MySQL table for holding registration data (4 points)
- Successful implementation and use of a site configuration file (4 points)
- Well-designed forms for login and registration (4 points)
- Successful connection to database (4 points)
- Appropriate insertion of registration information into database (4 points)
- Successful verification of login and password (4 points)
- Valid XHTML and CSS (4 points)
- Thorough self-assessment (22 points)
Directions
In this assignment, you will be creating the structures necessary to make a 'four-page web site' in which one of the pages can only be viewed by people who have registered with your web site. You will do this by creating six files
- A configuration file -- This file will contain information which is used by all three of the other files. Specifically, it will take care of displaying the HTML header information for each page as well as the general logo and navigation menu for your site. It will also establish a connection to the MySQL database.
- A CSS file -- This file defines all the styles for your site. It will automatically be linked to each page of your site by the configuration file mentioned above.
- A login page -- This file will display the login form for a user and a link to the registration page for users who have not yet registered.
- A registration page -- This file will display the form a user can use to choose a login and password for use in accessing 'members only' areas of your site.
- A registration processing page -- This file will process the information from the registration form and insert it into the database.
- A 'members only' page -- This file will process the information from the login form and display different messages depending on whether or not the user has successfully logged in. Successfully logged in users should be shown some sort of congratulatory message while all other users should be provided with a link to the login page.
Templates for these six files are provided here as a zipped folder: 05templates.zip
If you are unable to extract the folder on your own computer, send a message to Allen. He will send you an email with the folder as an attachment. You will want to save the files to your grace web space.
It is your task to modify these templates so that they contain the necessary form elements and successfully interact with your own database table to achieve the desired functionality.
Self-assessment
Your self-assessment should include the following components:
- Assign yourself a grade (using the criteria listed above) and provide evidence for the grade you have given yourself.
- Briefly describe the database table you use for your 'four-page web site' including descriptions and justifications for the data types used in each column of your table.
- Briefly describe the purpose of the configuration file and the pros and cons of using it as part of a web site.
- Evaluate the pros and cons of the over structure of your 'four-page web site' and suggest other ways to make the files more efficient, especially if they were used as part of a larger web site.
- List and explain at least three concepts which this assignment helped you clarify or which this assignment inspired you to pursue further.
- Assess your level of competence in relation to each of the objectives.
- State any plans you have for further work needed to reach the objectives.
Submission
- Create a discussion in your WebX portfolio in which you provide a link to your 'four-page web site' on grace. Attach three of your files. (You can only attach three files to a single message in WebX.)
- Post another message to the WebX discussion you just created in which you paste the output from the MySQL 'describe' command for the database table you use in your 'four-page web site.' Attach your remaining three files of code to this message.
- Finally, post another message to your WebX discussion in which you paste your self-assessment. Please take some time with this self-assessment. It should function as part of a rough draft for your program self-evaluation this quarter.