O'Reilly logo

PHP, MySQL, & JavaScript All-in-One For Dummies by Richard Blum

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 5

Communicating with the Database from PHP Scripts

IN THIS CHAPTER

check Examining the PHP database libraries

check Connecting to the MySQL server

check Submitting SQL queries

check Retrieving result set data

check Exploring a PHP database application

In the previous chapter, I show you how to insert, delete, and manage data in a MySQL database. Now that you have your content all ready for your application, there’s just one more piece to add in the assembly line to complete your dynamic web applications. This chapter explores how you can interact with the MySQL database server from your PHP programs to retrieve the stored data, add new data records, and remove existing data records. This chapter first explores how PHP interacts with databases in general. Then it focuses on the most popular method used for accessing MySQL databases from web applications: the mysqli library.

Database Support in PHP

The PHP programming language doesn't have any functions for accessing databases directly built into the language. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required