Contenu du cours
Module 1 — Discovering PHP
Understand what PHP is, set up a local environment and write your first script.
0/4
Module 3 — Functions, arrays and forms
Create functions, work with arrays and handle data coming from a form.
0/4
PHP for beginners

To run PHP on your own computer, you need a local server. The easiest route is to install an all-in-one package that bundles the web server, PHP and a MySQL database.

Common tools

  • XAMPP — cross-platform (Windows, macOS, Linux).
  • WAMP — for Windows.
  • MAMP — for macOS.
  • Laragon — lightweight and popular on Windows.

The steps

  1. Download and install the tool of your choice.
  2. Start the Apache (web server) and MySQL services.
  3. Put your files in the htdocs folder (or www).
  4. Open http://localhost in your browser.

If the page loads, everything works! Any .php file you drop into that folder will now be interpreted by PHP.

Key point: a local server (XAMPP, Laragon and so on) lets you test PHP without publishing your site online.

Prix indicatifs, convertis depuis l'euro