About Lesson
Installation PHP?
You can set up PHP using software bundles like:
-
XAMPP (Windows/Linux)
-
WAMP (Windows)
-
LAMP (Linux)
-
MAMP (Mac)
Steps:
-
Download and install XAMPP
-
Place your
.php
files in thehtdocs
folder -
Start Apache server from the XAMPP control panel
-
Open browser and navigate to:
http://localhost/yourfile.php
What is the PHP file and Extension?
PHP files have the .php
extension and contain code inside <?php ?>
tags.
PHP
<?php
// This is a PHP file
echo "This is my first PHP page.";
?>