Monitoring Errors Across Multiple Stacks with Sentry
Introduction In the world of software, there’s a famous saying: “If you haven’t experienced an error, you haven’t written any code”. As our apps grow, so do their complexities and potential error points. This is where Sentry comes into play, an open-source error tracking tool that integrates with a variety of platforms. In this blog […]
A Comprehensive Guide to Using PHPCompatibility in Your Project
Introduction PHPCompatibility is a set of PHP_CodeSniffer rules that checks your code for cross-version compatibility. It can help you ensure your code runs smoothly across various versions of PHP, making it an invaluable tool for any PHP developer. This guide will walk you through how to install and use PHPCompatibility in your project. Resulting […]
How to safely remove database indexes (without bringing down your application)
Safely remove database indexes by first disabling them
Detecting if an IP address is in a certain range in PHP
Here is another trick that can make your job easier! If you ever need to detect whether an IP address (let’s say 192.168.0.2) is inside a certain IP range/subnet (let’s say 192.168.0.0/24), you can use the following function in PHP : /** * Check IPv4 address is within a range * * @param string […]