The LAMP stack is the most popular stack used for PHP development and to host the websites and applications. This tutorial is specific to Ubuntu as a Linux system.
Updates: The newer version of this tutorial is available at The Complete Guide To Install LAMP Server(Ubuntu, Apache, MySQL, PHP) Using Ubuntu 20.04 LTS.
L for Linux
It stands for the underlying operating system. The Linux based operating systems are considered as secure systems as compared to windows based systems. One of the reasons is that the viruses can't execute in the absence of executable files. There are several other factors that make Linux the default choice to host websites and web applications. The popular Linux based operating systems include Red Hat Enterprise Linux (RHEL), CentOS, Ubuntu, Fedora, and SUSE Linux.
You can refer to Complete Guide To Install Ubuntu 18.04 LTS (Bionic Beaver) to install Ubuntu Desktop.
A for Apache
Apache is the most popular web server used to host PHP based websites and applications. It can also be installed locally for development purposes. The other popular alternative to Apache is NGINX which is popular for Load Balancing and also used as the proxy server to Apache.
You can refer to How To Install Apache 2 On Ubuntu 18.04 LTS to install Apache on Ubuntu.
M for MySQL or MariaDB
MySQL is used as the relational database to store the data specific to both websites and web applications. It can also be used either as a relational database or NoSQL for storing data. After the acquisition of MySQL by Oracle, the open-source community started contributing to MariaDB which is almost similar to MySQL using the same standards. MySQL differentiates more with MariaDB after the release of MySQL 8.0.
You can refer to How To Install MySQL 8 on Ubuntu to install MySQL on Ubuntu.
P for PHP
PHP is the widely-used open source general-purpose scripting language to develop websites and web applications. The recent versions of PHP support OOPS and types to develop the applications following Object Oriented paradigm. It can also be used as templates or dynamic pages to generate the HTML.
You can refer to How To Install PHP 7 On Ubuntu 18.04 LTS to install PHP 7 on Ubuntu.
The other tutorials relevant for PHP development are listed below.
Install Netbeans for PHP development - How To Install NetBeans 11 for PHP on Ubuntu.
Install VSCode or Visual Studio Code for PHP development - How To Install VSCode For PHP On Ubuntu.
Install Eclipse 2019 for PHP development - How To Install Eclipse for PHP on Ubuntu
Install Workbench to manage MySQL and MariaDB database systems - How To Install MySQL Workbench On Ubuntu
We can easily install a LAMP stack by following the links mentioned in this tutorial and start developing PHP based websites and applications using Netbeans, VSCode, or Eclipse.