Time as a Dependency: Advanced Patterns with the Symfony Clock
With Symfony 7.3 (released May 2025) and PHP 8.4, the symfony/clock component is no longer just a...
With Symfony 7.3 (released May 2025) and PHP 8.4, the symfony/clock component is no longer just a...
Arrow functions were introduced in PHP 7.4 to allow devs to write short, anonymous functions. They offer a compact alternative to traditional closures, especially when the function body is small and focused. In this article, you will learn how to use...
Now with PHP 8.4 out of the box! 🚀"PHP 8 in a Nutshell" is a book that clearly and concisely summarizes all the new and important features of PHP 8 without all the fluff. The book covers all of PHP 8's developer-facing features in a concise format that covers the important nitty-gritty and what you would want in a real-world scenario.The book also covers the newest minor releases, PHP 8.1, 8.2, 8.3, and 8.4, and their features and enhancements.You'll get two nicely structured eBooks in PDF. One is in light mode, and the other is in beautiful dark mode if you prefer that.You'll also get the book in the EPUB format.Bonus: Once you buy a copy, you'll be entitled to get all the future updates to the book at no extra cost.So, what are you waiting for? Go and grab your copies now!Download the sample eBookAlso, be sure to rate the book if you like it! 🫶
The switch statement in PHP is great when you want check condition on the same expression without incorporating many if statements altogether.
Attributes are a powerful feature in PHP that can be used to add structured, machine-readable metadata to annotate your code. In this article, we'll look at what attri...
The Batch API is a powerful feature in Drupal that allows complex or time consuming tasks to be split into smaller parts.For example, let's say you wanted to run a function that would go through every page on you Drupal site and perform an action. This might be removing specific authors from pages, or removing links in text, or deleting certain taxonomy terms. You might create a small loop that just loads all pages and performs the action on those pages.
Aljibe is a set of testing tools and best practices built on top of DDEV to help you develop Drupal projects. Discover all its capabilities and enhance the quality of your projects with ease.
Are you using PHP and want an easy way to deploy your application to Google Cloud? Follow this guide to deploy your app with Google Cloud Run in under 10 minutes.
With the release of Drupal 11.1, there’s a cool new feature for developers: Hooks can now be implemented as class methods using PHP attributes instead of functions. This change is a major step forward in modernizing Drupal’s codebase. While procedural function-based hooks are still supported (and will be for some time), developers writing new code should strongly consider using the object-oriented (OOP) approach introduced in Drupal 11.1. One of our core commitments at Drupalize.Me is ensuring that our tutorials remain accurate and relevant as Drupal evolves. So we’re working on updating all of our tutorials to take into account the new OOP approach to adding hooks in a module. We’re also aware that procedural hooks have been around for 24 years, and aren’t going to disappear overnight. You’ll see them in example code and existing documentation for a long time to come. So for now we’ll be including both approaches in our content whenever doing so makes sense. You should plan on learning both approaches, and then using the one that makes the most sense given your specific case. Continue reading to learn a bit about the evolution of hooks in Drupal core and how to implement hooks as classes in Drupal 11 in this latest Drupalize.Me blog post by Joe Shindelar.
A step-by-step journey to discover the tricks to memory-manage large PHP arrays.