Test Your Knowledge

  1. Form data can be submitted using either the POST or the GET method. Which associative arrays are used to pass this data to PHP?

  2. What is register_globals and why is using it a bad idea?

  3. What is the difference between a text box and a text area?

  4. If a form has to offer three choices to a user, each of which is mutually exclusive (so that only one of the three can be selected), which input type would you use for this, given a choice between checkboxes and radio buttons?

  5. How can you submit a group of selections from a web form using a single field name?

  6. How can you submit a form field without displaying it in the browser?

  7. Which HTML tag is used to encapsulate a form element and supporting text or graphics, making the entire unit selectable with a mouse-click?

  8. Which PHP function converts HTML into a format that can be displayed but will not be interpreted as HTML by a browser?

See Chapter 11 Answers in Appendix A for the answers to these questions.

Get Learning PHP, MySQL, JavaScript, and CSS, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.