Buy Best MIS582 Lab 7-New(4th Lab)
Buy Best MIS582 Lab 7-New 4th Lab
Name your MySQL database Lab4_xxxx where XXXX is your user. Create and save your MySQL database file. You will be required to submit a web link to your index.php file, along with 6 PHP script files and a SQL file that will be executed from the Omnymbus public Web page from your Omnymbus account. Please note that your PHP and SQL files will be based upon the templates provided in the zip file titled MIS582_Wk7_templates.zip located in the folder titled iLab Documents in Doc Sharing.
You will need to modify the following PHP scripts and SQL file from the MIS582_Wk7_templates.zip file.
• index.php
• insert.php
• insert_data.php
• update.php
• update_data.php
• delete.php
• MyAddressBook_CreateTable.sql
When you are done, submit your index.php link and zip file to the Week 7 Course Dropbox.
Required Software
Omnymbus – MySQL
Access the software at https://devry.edupe.net:8300.
Steps 1-7
Lab Steps
STEP 1: Review the Data Dictionary
Review the provided data dictionary below to understand the entity, attributes, and primary key that you will create in your MySQL database.
Table Name ATTRIBUTE NAME CONTENTS TYPE FORMAT RANGE REQUIRED PK or FK
Addressbook id Contact ID Number Auto-Increment
Int(3) 999 000-999 Y PK
f_name Contact First Name VCHAR(25) Xxxxxx Y
L_name Contact Last Name VCHAR(25) Xxxxxx Y
ADDRESS Contact Address VCHAR(25) Xxxxxx Y
City Contact City VCHAR(25) Xxxxxx 0-9 Y
State Contact State CHAR(2) Xxxxxx Y
zip Contact Zip Code NUMBER(5) 99999 Y
phone Contact Phone NUMBER(10) 9999999999 Y
STEP 2: Create Table, Insert Statement
• Run MySQL via Omnymbus.
• Modify the table creation script that will be used to create the database with the outlined attributes from the Data Dictionary.
• Provide one Insert Statement that will add your contact information to the newly created table.
• Save the file with a name containing Lab7_, your first initial, and your last name (e.g.,Lab7_JSmith.sql).
• Execute your script and ensure that the database is created.
STEP 3: Build Index PHP Page
Building Your index.php Web Page
In this step, you will complete your PHP script page to connect to the Lab7 database and display the MyAddressbook table on the Web page.
• Complete the MySQL connection for the index.php page. Be sure to fill in the appropriate host (127.0.0.1), username, password, and database information in the MySQL field.
• Modify the provided PHP code to display each attribute of your MyAddressbook table. Note that initially, only 1 entry should be present in your table.
• Save your index.php file in your public_html folder in Omnymbus file manager.
• Please note that you will find your public_html folder down the path disk/USERID/public HTML
• Direct your Web browser to your site URL (ex. http://devry.edupe.net/~XXXX/index.php).
• Note that you’ll replace XXXX with your Omnymbus login ID.
• Ensure that your file executes and the database table displays on the screen.
• If you have a correct connect command but you get the error message “MySQL ERROR 1045 (28000): Access denied for user” you will have to create a new password with the box “Change password in other modules?” checked.
• The following image provides an example of how your index.php page should look with no entries provided in the database. Note: Feel free to add any additional formatting or images to your index.php page.
STEP 5: Build Update PHP Pages
Building Your update.php and update_data.php Pages
In this step, you will complete two PHP HTML pages. Your update.php page will provide a form for users to submit data to the database that will be updated. The update_data.php page will provide the actual queries in PHP to update the data in your database. When this process is complete, your page will redirect the user back to the index.php page.
• Review the update_data.php page template.
• You will need to modify the PHP code to add additional input forms for the user to enter all appropriate attributes that will need to be updated.
• In the update_data.php file, ensure that your