Program3.php and its includes

Pataasin ang iyong marka sa homework at exams ngayon gamit ang Quizwiz!

Using an if statement and the $rowcount and $comments variables, display the results of the find program when successful.

Hint: "<span style=\"color: blue\">

Using an else if, Display the results of find if the telephone that the user entered was empty. (Logical if uses telephone variable)

Hint: "<span...>"

What does the trim function do?

Removes the spaces from the front and end of a variable or input.

Using a while loop, get the data from the row in which the primary key (telephone) and the user input for telephone matched.

Hint: $Telephone = $row['Telephone'];

Using an if statement, how would you check to see if the record was actually found in the delete program?

Hint: Same in modify program

Using an if statement, how would you check to see if the record was actually found in the modify program?

Hint: Telephone and trim

Why do you need to get the number of rows from the result sql query?

If there are no rows, the query didn't actually obtain any information.

In the "link" tag in program 4 in the head section of the html, how do you enable css?

<link rel...

What are the steps in the find.php program?

1. Get info from customer table 2. Perform select query and check if it is successful 3. If successful, get all fields from the matching row 4. Trim telephone 5. Display results of find(success, telephone cannot be empty, or problem updating)

What are the steps in the delete.php program?

1. Get variable $found (you need to use find program first 2. Create sql query to delete from customers where telephone = $telephone 3. trim telephone 4. Check if matching info (same "if" as modify) 5. if success, check if delete query is successful, if yes, display success, if not, display error. 6. else, record does not exist.

What are the steps in the modify.php program?

1. Get variable $found (you need to use find program first) 2. check if matching info if((strlen(trim($found)) > 0 && ($found == $Telephone) 3. If success, create mysql query to update info where telephone = $telephone 4. Display results of modify (success, problem updating, or must be found first)

What are the steps to connect to the sql server in Controller3.php?

1. connect 2.chcek if connection successful, select database 4. create table if the table has not yet been created

Write the html for a text input for telephone with a placeholder, and a tool tip that comes from the text input label.

<td width="33%"><div class="tooltip"> <font size="5" face="Verdana">&nbsp; Telephone &nbsp;</font><span class="tooltiptext2">Required</span></div> <input type="text" placeholder="Telephone" name="Telephone" value="<?php echo $Telephone ?>" size="22" > </td>


Kaugnay na mga set ng pag-aaral

Principles of Microeconomics Exam 4

View Set

Principles Of Biology 1 (Evolution & Viruses)

View Set

Psychology - Ch. 6-8 Study Guide

View Set

Nurs 310 Fluid/electrolyte prepu questions

View Set

Chapter 13: Unique Nutrition Issues in the Older Adult

View Set

Topic 6: Relational Database Management Systems

View Set

Florida Statutes, Rules, and Regulations Pertinent to Life Insurance

View Set