Chapter 5. Communicating with the Database from PHP Scripts

In This Chapter

  • Using PHP built-in functions to access MySQL

  • Sending SQL queries to the MySQL server

  • Understanding how to handle MySQL errors

  • Using other helpful functions

  • Changing functions from mysqli to mysql

PHP and MySQL work well together, and this dynamic partnership is what makes PHP and MySQL so attractive for Web database application development. Whether you have a database full of information that you want to make available to users (such as a product catalog) or a database waiting to be filled by users (for example, a customer database), PHP and MySQL work together to implement your application.

This chapter describes accessing MySQL from PHP scripts.

Get PHP & MySQL® Web Development All-in-One Desk Reference for Dummies® 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.