I’ll go through how to use soft delete in Laravel 10 in this post. The soft deletes are a method of deleting data in an application without removing it from the database. Why do we need Soft Delete? The application’s data is crucial, and since many users often work on the same records and accidentally erase […]
in this Laravel tutorial, I will explore common practices for using the Laravel Blade template with examples. Blade is a templating engine in Laravel that helps developers create dynamic views. Here, you can pass variables, add conditional views, and perform various operations on variables to present views.
in this article, we’ll discuss some useful methods of Laravel eloquent model class. The methods are: firstOrNew(), firstOrCreate(), firstOr(), and updateOrCreate(). We’ll discuss some useful tips and examples of each of them. Larave Elequonte Method Let’s explore four essential Eloquent methods: firstOrNew, firstOrCreate, firstOr, and updateOrCreate with example. firstOrNew : Retrieve Or Create a New […]
We’ll look at PHP string interpolation with an example of best practices in this article. Developers can directly embed variables into strings with the help of string interpolation, which also makes variable concatenation easier and makes code easier to read. What is String Interpolation The process of evaluating variables and expressions within a string and […]
in this tutorial, We’ll explore different ways to implement Eloquent whereIn in the Laravel application. This method allows you to filter query results based on a set of conditions.