Kirkwood Center for Continuing Education Introduction to PHP and MySQL By Fred McClurg, © Copyright 2014 All Rights Reserved.
Recipe DB Application Part Two: Insert & Update Class Project urses/php/slides/recipe02.ppt
Description: Top level design is a methodology that addresses the large picture first and then the details. For today’s in class project, will apply that methodology. Top Level Design
Discussion: The items below are the tasks and the procedure we will follow to complete the “create.php” application. 0.Create the page layout in HTML. 1.Convert HTML form to PHP. 2.Make form action self-referential. 3.Make the fields “sticky”. General Tasks
4.Connect, use and close the database (Steps 0, 1, 2 and 6). 5.Create function that populates drop down list with database values. 6.Determine if a submit button was pressed and which one. 7.Build the SQL statements for “SELECT”, “INSERT” and “UPDATE” (Step 3). General Tasks (continued 2)
8.Output SQL debug statements. 9.Execute SQL statements (Step 4). 10.Obtain results from INSERT. 11.Obtain results from UPDATE. 12.Obtain results from SELECT. General Tasks (continued 3)
13.Protect SQL from “bad” SQL values. 14.Status message INSERT & UPDATE. 15.Pop-up error dialog messages. General Tasks (continued 4)
to be continued... urses/php/slides/html5.ppt