7 HTML FormsThis is NOT the latest copy of this book; click here for the latest version.
PHP was originally designed for use on the Internet, and although you can now use it for command-line apps and GUIs, its main purpose remains working on the web. When it comes to the web, HTML has ruled unchallenged for some years now as the de facto standard for displaying information, even more so now that WAP usage has evaporated. This means that if you want to write a front-end for your PHP web applications, you need to understand HTML.
Topics covered in this chapter are:
Chapter contents7.1. The state of play
7.2. What does it mean to be dynamic?
7.3. Designing a form
7.3.1. GET and POST
7.3.2. Available elements
7.3.3. A working form
7.4. Handling data
7.4.1. register_globals
7.4.2. Working around register_globals: import_request_variables()
7.4.3. Magic quotes
7.4.4. Data handling summary
7.4.5. Handling our form
7.5. Splitting forms across pages
7.6. Files sent through forms
7.7. Validating input
7.7.1. Client-side validation
7.7.2. Server-side validation
7.7.3. Validation in practice: is_string(), is_numeric(), is_float(), is_array(),is_object(), and is_resource()
7.7.4. Advanced variable validation using CTYPE
7.7.5. Key validation points
7.8. Form design
7.9. Summary
7.10. Exercises
7.11. Further reading
7.12. Next chapter
|
Want to see this stuff in print? PHP in a Nutshell takes the core topics covered here, adds in thousands of edits from the editorial team and myself, and combines them to make an unbeatable reference for PHP programmers at all levels.
My latest book has hundreds more tips on how to use PHP, Apache, and MySQL, plus Perl, Python, shell scripts, performance tuning, and more!
|