From the course: PHP: Object-Oriented Programming with Databases

Unlock the full course today

Join today to access over 22,700 courses taught by industry experts or purchase this course individually.

CRUD operations

CRUD operations - PHP Tutorial

From the course: PHP: Object-Oriented Programming with Databases

Start my 1-month free trial

CRUD operations

- In this chapter, we'll be learning to perform the remaining database operations so that we can implement the object oriented active record design pattern. We're going to be looking at four main operations, and the abbreviation for these is CRUD, c-r-u-d. C is for create, R is for read, U is for update, and D is for delete. Those are the four primary ways that we interact with the database. We create new records, we read existing records, we update existing records, or we delete records. So far, we've already seen how we can read from the database when we learned how to do find all and find by ID. Now we need to learn how to implement the other three. The way that we're going to add that to our project is that we're going to create a staff area, a content management system that'll allow the Chain Gang staff to log in and be able to update the inventory of bicycles using a web interface. They'll be able to create records, update records, delete records, and so on. So the code work…

Contents