MySQL count for multiple conditions
MySQL COUNT allows you to count rows in your MySQL database, a useful way to use this is to apply a condition like: SELECT COUNT(*) FROM invoices WHERE `paid` =…
MySQL COUNT allows you to count rows in your MySQL database, a useful way to use this is to apply a condition like: SELECT COUNT(*) FROM invoices WHERE `paid` =…
Testing the speed with 3 methods to save or download an image in PHP, each method was run twice and then the average time was used with the output filename…
Comparing Imagick a PHP image plugin JPG image file compression from 1 (lowest) through to 100. The original image was 1MB and the code used to do this test was:…
A simple method to view a PHP pages load time in seconds can be done with the use of microtime(). Microtime when called counts in microseconds, using microtime true makes…
Fetching a Sub Reddits latest posts is actually easy, mostly because the Reddit API is free and you don’t need a key. You can do self archiving with PHP and…
If you want to check if a row will be returned using PHP and MySQL you can use mysqli_num_rows which counts how many rows will be returned from the query….
Thanks to this post by SteveMC at Lowendtalk PHP versions were benchmarked using php-benchmark-script.com On a reported Intel i3 3240 – 8GB ram, from version 7.0 through to the latest…
Here is a way to resize images in PHP without needing a framework like ImageMagick or GD The below code is derived from here. With the function resize_image taking into…
Simple and fully responsive, this image grid includes a text overlay to put the image title. Made to have minimal white space it is a perfect template for a gallery…
Here is how to view the local host of your network on another device. You may be running XAMPP on your computer and want to check it out from a…