Summary

Today you had a crash course in PHP, learning the basics of the language, how to incorporate PHP scripting into your Web pages, and how to use it to communicate with a MySQL database.

You should now be able to write PHP scripts that use the include statement for incorporating one file into another. You saw how to create user-defined functions and how to use the control structures if, for, and while. You learned how to handle arrays, both in general use and when created as a result of a SELECT query from a database.

You saw how to connect to a MySQL database and how to run queries, iterating through a resultset of data and processing it row by row. You also learned how to run database queries that return no resultset while determining ...

Get Sams Teach Yourself MySQL in 21 Days, Second 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.