Introduction

In this project you will continue working on integrating Web pages with the database.  This project applies what you learned in previous projects, so be sure to do those before you try this project.  These database functions are somewhat complicated, so it wouldn't hurt to repeat them a few times for practice until you understand the concept of sending a URL parameter and moving to a specific  record or filtering the recordset based on that parameter.

For this project, you will create a page to add a record and a page to update a record in the Contacts database.

This assignment will be easier if you view my examples before you begin.  See my add page and my list of links (click update to go to update page).

 

What to Do

  1. You should already have a working connection (connContacts ).
  2. Open add.php.  Use the Record Insertion Form Wizard to create a form to add a new record.  Add spry form field validation and be sure you are linked to CSS. Save, upload, and test.
  3. Open list.php and add a link to add.php at the bottom of the page.
  4. Add the word "update" after the link description -- make sure this is part of the repeat behavior. Save, upload, and test.  When you test, you should see update next to every record. (See my example.)
  5. Select the word update and link to the update page. Use the folder icon next to the link box in the property inspector to make the links, and click the Parameters button to select num as a parameter.  You can name the URL parameter whatever you like, but remember the name since you will need it in the next step. 




  6. Save, upload, and test.  When you test, click the update link and examine the URL parameter. 
  7. Open update.php and create a recordset with a filter so that the page only displays the record of interest (parameter passed in query string matches num in recordset).
  8. Use the Record Update Form Wizard to create a form that will update a record. Add spry validation.
  9. Save, upload, and test.  When you click update on list.php, you should see the appropriate record appear.  You should be able to change values in fields and update your record.  Your file should work like my example

 

Submitting work

Grading - 60 points

Points Requirements
15 record insertion form works
5 list links to add page
5 "update" is next to every record
10 "update" links to the update page with a correct query string
15 page displays appropriate record
10 update form works