In this video, learn how to update and delete records in your database using the Eloquent system and explore how easy it is to update your database to reflect changes from your users.
- [Instructor] Updating is going is going to … be pretty easy to follow along … after we have worked out saving records using … Eloquin. … We'll start in our controller app. … Http, controllers, … bookingcontroller.phv … We'll scroll down to our update method, headline 90. … And what we'll need to do is erase from lines 92 to 101. … And now with 92, we'll just add … booking, … arrow, fill, … request, arrow, input. … This very simply fills our model … and populates it with the data from the form. … And then on line 93, we can save it with … booking, arrow, save. … Let's try it out and verify that everything works. … We'll go to our browser. … We'll edit a record. … And in this case, I will just change the date. … And if we update our reservation, … we'll see that our start date was updated. … That's how pretty easy it was to save … and update records with Eloquin. … Destroying is also pretty straight forward. … So we'll do that as well. … We'll go back to our controller again. … And we'll scroll down to our destroy method on line 108. …
- Exploring Laravel
- Setting up simple authentication
- Controllers and routes
- Create and index view
- Show, edit, and destroy views
- Writing scopes in Laravel Eloquent
- Creating one-to-one relationships
Skill Level Beginner
MVC Frameworks for Building PHP Web Applicationswith Drew Falkman2h 57m Intermediate
Ajax with PHP: Add Dynamic Content to Websiteswith Kevin Skoglund3h 37m Intermediate
What you should know1m 52s
2. Starting Your Project
3. The Create and Index Views
4. The Show, Edit, and Destroy Views
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.