1: Auto Model Validation Automatically validate model or anything you want to perform before save, update or create. 2: Prevent Update Some times you want to prevent update on any model, for this purpose you can use code written below: 3: Get Random Rows Get random rows from a table using Eloquent: 4: Make UUID […]
In this tutorial I will guide you on how to execute stored procedure from Laravel. The stored procedure can be execute from Laravel by following ways: Procedure with parameters, first approach Procedure with parameters, second approach Simply call stored procedure without parameters
Since its release in 2011, Laravel has become popular choice for the development of business focused applications. One reason Laravel is too much popular in developers is its performance optimization that allows developers to fine tune Laravel based apps. In this tutorial I will guide on how to optimize Laravel based application when in production. […]
In this tutorial I will guide you on how to use multiple databases in Laravel. Step1 — Add following in your .env file Step2 — Add following at config/database.php Step3 — Add following at app/config/database.php Specify connection during migration Specify connection in QueryBuilder Specify connection in Eloquent Models Setting connection at run time
When it comes to Laravel Facades; Facades are often discussed topic, people love them, people hate them there is almost nothing in between it. One of the main reasons is that many developers don’t know what Facades are, and how do they really work. In this post I will explain what Laravel Facades are and how they work.
Laravel Telescope is an open source debugging assistant by Laravel, written by Taylor Otwell and Mohamed Said. It is open source, free and available on Github as well as it is documented on Laravel site. You can pull Telescope as a dependency from composer and it is accessible at /telescope.
Laravel is full of hidden gems that I have discovered during working on different tasks. Some of these gems were less-known or un-documented features, functions parameters and hacks. In this blog post I will share those hidden gems with you, let’s get started.
Maat Website’s Laravel Excel is a Laravel package build as a wrapper on PHPExcel in previous version of this package and in its latest version it uses PHPSpreadsheet. In this tutorial I will guide you on how to extract images from excel files using Maat Website’s Laravel Excel.