To run PHP pages, we need to install a software called a web server. For PHP, Apache is such software. Also, we you need to run dynamic PHP websites, you must install database. XAMPP is a bundle of such software which have Apache server, MYSQL database.
About XAMPP: Introduction
XAMPP is free-to-use Apache Distribution package. Acronym XAMPP stands for X-Operating System it runs on, A-Apache , M-MYSQL/MariaDB , P-PHP, a servers-side language and Last P for Perl, a scripting language.
Apart from above components, XAMPP also contains phpMyAdmin for database administration,Apache Tomcat and FileZilla.
Installing XAMPP:
Following is step-by-step tutorial for installing XAMPP on Windows machine.
Step 1- Go to Download XAMPP (apachefriends.org).
Step 2-Download Latest version of XAMPP.
Step 3- Double Click the downloaded file to run it.
Step 4-Click Yes on pop-up window.
Step 4-Click Ok on next popup.
Step 5-Start the XAMPP setup wizard. Click on ‘Next’ button to configure the installation settings.
Step 6- Choose the software components you want to install. Click on ‘Next’ button to proceed.
Step 7-Choose the installation directory and click on ‘Next’ button to proceed.
Step 8- Select Language.
Step 9- Begin installing XAMPP. Click on ‘Next’ button and it will begin installing its files.
Process of installation will begin.
Step 11-Complete Installation.
Once all the components are unpacked and installed, click ‘Finish’ button to close the setup wizard.
Step 12-Open the XAMPP.
Step 13-Starting software modules
Test your XAMPP installation:
Step 1- Go to htdocs folder-C:\xampp\htdocs
Step 2- Create a php file- test.php
Step 3- write following code in test.php file.
<?php
echo "Hello";
?>
Step 4- Open any browser and type localhost/test.php
You should get Hello as output.