Learn PHP

If you want to be a web developer, you need to learn PHP. Read these free tutorials to master this powerful and popular scripting language.

Getting started with PHP

  • How to Build a Simple REST API in PHP

    How to Build a Simple REST API in PHP

    Sajal Soni
  • How to Use Sessions and Session Variables in PHP

    How to Use Sessions and Session Variables in PHP

    Sajal Soni
  • How to Upload a File in PHP (With an Example)

    How to Upload a File in PHP (With an Example)

    Sajal Soni
  • All PHP tutorials:

    1. How to Set Up a Full-Text Search Using Scout in Laravel

      How to Set Up a Full-Text Search Using Scout in Laravel

      Tutorial Intermediate

      Full-text search is crucial for allowing users to navigate content-rich websites. In this post, I'll show you how to implement full-text search for a Laravel...

    2. How to Zip and Unzip Files in PHP

      How to Zip and Unzip Files in PHP

      Tutorial Intermediate

      This tutorial will teach you how to zip and unzip (compress and extract) files to and from a zip archive in PHP. You will also learn how to delete or rename...

    3. Manipulating Images in PHP Using GD

      Manipulating Images in PHP Using GD

      Tutorial Intermediate

      This tutorial will cover the basics of manipulating images using the GD library in PHP. We will begin with basic operations like resize and rotate, before...

    4. WP_Query Arguments: Taxonomies

      WP_Query Arguments: Taxonomies

      Tutorial Intermediate

      In the next part of the series on the WP_Query class, learn how to add arguments for taxonomy terms to WP_Query.

    5. Build a React App With a Laravel Back End: Part 2, React

      Build a React App With a Laravel Back End: Part 2, React

      Tutorial Intermediate

      In this second part of our series on building a React application with a Laravel back end, we will be developing a front end to the API using React.

    6. WP_Query Arguments: Posts, Pages, and Post Types

      WP_Query Arguments: Posts, Pages, and Post Types

      Tutorial Intermediate

      Creating custom queries for specific posts or post types with WP_Query gives you a lot of flexibility. Here are the arguments to use.

    7. Notifications in Laravel

      Notifications in Laravel

      Tutorial Beginner

      In this article, we're going to explore the notification system in the Laravel web framework. The notification system in Laravel allows you to send...

    8. How to Create a Laravel Helper

      How to Create a Laravel Helper

      Tutorial Beginner

      Helpers in Laravel are built-in utility functions that you can call from anywhere within your application. In this tutorial, you'll learn how to create your...

    9. How to Return Multiple Values From a PHP Function

      How to Return Multiple Values From a PHP Function

      Tutorial Beginner

      This tutorial will show you how to return multiple values from a PHP function using two different approaches.

    10. Custom Events in Laravel

      Custom Events in Laravel

      Tutorial Beginner

      In this article, we are going to explore the basics of event management in Laravel. We'll also create a real-world example of a custom event and listener.

    11. Render Text and Shapes on Images in PHP

      Render Text and Shapes on Images in PHP

      Tutorial Intermediate

      This tutorial will teach you how to draw basic shapes in PHP and how to render text using your favorite font.

    12. 18 Best Contact Form PHP Scripts for 2025

      18 Best Contact Form PHP Scripts for 2025

      Tutorial Beginner

      Are you looking for an easy-to-use contact form PHP script? Contact forms are a must-have for every website, and with 14 premium scripts from CodeCanyon and...