This short tutorial will show you how to use the PHP sleep() and usleep() functions to pause script execution for a number of seconds/microseconds, and provide some code examples. The PHP sleep() and usleep() functions both pause execution of the script, but both behave a bit differently. Why Pause/Sleep PHP Script Execution? Delaying, sleeping, or… Read More »Using PHP sleep() and usleep() to Pause Execution [Examples]
This article will quickly walk you through how to comment your PHP code with single and multi-line comments. What is a Comment? A comment in programming is one or more lines of text that aren’t interpreted as programming instructions. Instead, the computer skips the commented lines when executing… Read More »How to Use Single/Multiline Comments in your PHP Code
This article will explain what the PHP and Ruby programming languages are, what they’re best used for, and which one you should pick up in 2022. What is PHP? PHP: Hypertext Preprocessor. PHP a recursive initialism that contains its own name, just to make things confusing… Read More »PHP vs Ruby – Which One should I Pick for my Project in 2022?
This article will explain what the PHP and Python programming languages are, where they’re best used, and which one is most useful in 2022. What is PHP? PHP: Hypertext Preprocessor. PHP a recursive initialism that contains its own name, just to make things confusing for you: P PHP H Hypertext… Read More »PHP vs Python: Which Should You Learn In 2022? What’s the Difference?
This article will show you how to delete a single file or multiple files in PHP using the unlink() function, and provide code examples. Once you have file uploads working in PHP, you may want to allow your users to delete files they no longer wish to keep. Read… Read More »Deleting Files in PHP with unlink() [Examples]
This tutorial will demonstrate how to write data to a file on the server in the PHP programming language. Code examples are provided to show you how it’s done. Writing data to a file server-side is a common task. Whether you’re writing log files so… Read More »How to Write/Save to a File with PHP [Examples]
This tutorial will explain how to upload one or multiple files from the web browser to the server using PHP. Code examples are included, including the code for limiting file size and type. Being able to have your users upload files to your app has… Read More »Ultimate Guide to Uploading Multiple Files With PHP [Examples]
This tutorial will show you how to resize or crop images in the PHP programming language. Code examples are provided which can be copy and pasted into your project. GD Library vs ImageMagick Image resizing in PHP is performed by an optional image processing library.… Read More »How to Resize/Crop Images in PHP with the GD Library
This tutorial will show you to rename files and folders in PHP with the rename() function – including some code examples you can use in your own project. We’ve already covered uploading files and deleting files in PHP, read on to find out how to rename them. rename() PHP Function… Read More »How to Rename Files & Directories in PHP [Examples]
This article will show you how to output or display an image in the web browser from PHP, with a quick copy & paste code snippet. Images in PHP We’ve covered how to resize images in PHP using the GD library. Once an image is created, it… Read More »Output or Display an Image in the Browser from PHP