How to Write a Hello World Program in PHP

Before going into "Hello World" programme of PHP, Download & Install XAMPP in windows platform., After installation you can see a 'htdocs' folder(xampp\htdocs) in XAMPP installed folder., PHP coding starts with ., Save it.

5 Steps 1 min read Medium

Step-by-Step Guide

  1. Step 1: Before going into "Hello World" programme of PHP

    All PHP files should be inside of 'htdocs' folder. , A PHP file is combination of html tags and PHP code.

    Write the codes such as <?php echo "Hello World"; ?> Each code line in PHP ends with a semicolon(;).

    Echo and print are basically used for displaying information in browser. , The PHP file must be saved with the .php extension.
  2. Step 2: Download & Install XAMPP in windows platform.

  3. Step 3: After installation you can see a 'htdocs' folder(xampp\htdocs) in XAMPP installed folder.

  4. Step 4: PHP coding starts with <?php and ends with ?>.

  5. Step 5: Save it.

Detailed Guide

All PHP files should be inside of 'htdocs' folder. , A PHP file is combination of html tags and PHP code.

Write the codes such as <?php echo "Hello World"; ?> Each code line in PHP ends with a semicolon(;).

Echo and print are basically used for displaying information in browser. , The PHP file must be saved with the .php extension.

About the Author

C

Christopher West

Enthusiastic about teaching creative arts techniques through clear, step-by-step guides.

31 articles
View all articles

Rate This Guide

--
Loading...
5
0
4
0
3
0
2
0
1
0

How helpful was this guide? Click to rate: