PHP

PHP is a popular scripting language for web development. It can create dynamic and interactive web pages by running on the server and sending HTML to the browser. It is free, fast, and flexible,

Laravel + Eloquent: Store categories and subcategories in the same table

Updated: January 25, 2024 By: Guest Contributor

Introduction It’s common to encounter scenarios where items are organized in categories which themselves can have subcategories, forming a tree-like structure. In a traditional database, you might consider…

PHP: Inserting Custom Content After N-th Paragraph

Updated: January 25, 2024 By: Guest Contributor

Introduction When working with CMS platforms like WordPress or managing content-heavy websites, there may come a time where you need to dynamically insert custom content after a specific…

Eloquent: How to auto-delete old records after N days

Updated: January 25, 2024 By: Guest Contributor

Introduction When developing applications, it’s a common requirement to maintain a clean database by automatically removing old records. In this tutorial, we’ll explore how to set up an…

Inner Join in Laravel Query Builder: Tutorial & Examples

Updated: January 23, 2024 By: Guest Contributor

Introduction Laravel, known for its elegant syntax and feature-packed libraries, offers developers a fluent interface for database queries. Laravel Query Builder allows for intuitive and flexible interactions with…

Eloquent: Delete multiple records with an array of IDs

Updated: January 22, 2024 By: Guest Contributor

Introduction When working with databases in a Laravel project, Eloquent makes it easier to interact with your database by providing a robust set of functions to handle various…

How to Bulk Insert Data with Eloquent in Laravel

Updated: January 22, 2024 By: Guest Contributor

Introduction Bulk inserting data in a database is a common task for developers, especially when dealing with large amounts of data. Laravel, a popular PHP framework, provides an…

How to run background, heavy tasks in Laravel: An in-depth guide

Updated: January 22, 2024 By: Guest Contributor

Overview When building web applications with Laravel, running heavy tasks in the background is essential for ensuring quick response times and a smooth user experience. In this in-depth…

How to schedule tasks in Laravel: A developer’s guide

Updated: January 22, 2024 By: Guest Contributor

Introduction Task scheduling is an essential aspect of modern web application development. In Laravel, one of the most popular PHP frameworks, task scheduling is both powerful and simplistic…

Using Table Aliases in Eloquent: A Practical Guide

Updated: January 18, 2024 By: Guest Contributor

Introduction Laravel’s Eloquent ORM is a powerful tool for interacting with databases in an elegant and expressive manner. Eloquent allows developers to work with database records as if…

Laravel Eloquent: Finding SUM/COUNT/AVG of each group

Updated: January 18, 2024 By: Guest Contributor

Introduction Laravel Eloquent provides an intuitive and fluent interface for interacting with your database. When working with large datasets, particularly those with grouping requirements, you may often need…

1 3 4 5 6 7 95