How to run PHP programme on Xampp

Php is the widely used open source scripting language and most popular web backend programming language . Php scripts are executed from the server for that you need to install web server like Apache and you also need a database server like MySQL. To run php programme there are many web servers like WAMP and XAMPP. WAMP server is supported in windows and XAMP server is supported in both windows and Linux.

Below steps you need to consider:

Step1: What is Xampp?
Step 2: Installation of xampp
Step 3: How to run php programme in xampp

Let’s get started,


Step 1: What is Xampp?


Xampp is the most popular php development environment for windows, Linux, OS X. The use of Xampp is to test your website before uploading it to the remote web server .

The full form of Xampp ,is X stand for Cross plateform, Apache Server(A), MariaDB (M), PHP(p) and Perl(P). Cross platform means it can run on any computer with any operating system.


Step 2: Installation of Xampp


Xampp is easy to install Apache distribution containing MariaDB, PHP and Perl.
Download the Xampp from https://www.apachefriends.org/index.html .

On installation select the component you want to install.

Select the installation directory in which you want to install all the components.



Step 3: How to run run PHP programme in Xampp


  • Write your php programme and save it by any name with .php extension like firstphp.php
  • Place your php file in “htdocs” folder located under “xampp” on your C:drive(C:/Program Files/Xampp/htdocs).


  • In order to get the dashboard for loacalhost search localhost in any browser.


  • To run your code open localhost/firstphp.php then it gets execute

Like this you can use xampp server to run your php code.


Did you like our works?

We are known for Website Development and Website Designing, along with Android iOS application development in Mumbai, India. Please write us what you think, we would like to hear it from you

1