Install and set up PHP - ndgriffeth/Class-Notes-and-Lectures GitHub Wiki

Mac OS X

 1.  PHP is bundled with Mac OS X.  To activate it, edit the file 

      /etc/apache2/httpd.conf 

 and uncomment the line

      LoadModule php5_module libexec/apache2/libphp5.so

 2.  Restart apache with the command:

      sudo apachectl restart

 3.  Test PHP by creating the file phpinfo.php with one line:

      <?php phpinfo(); ?>

     in document root (you can use the Sites directory under your home directory). 
     If you don't have a Sites directory, create one using "mkdir Sites" from a terminal when
     you are in your home directory; or, from the Finder, create a "New Folder" in your home
     directory.

      Then browse to http://localhost/~<username>/phpinfo.php

Ubuntu

Install PHP5 and the Apache PHP5 module as follows:

 sudo apt-get install php5 libapache2-mod-php5

Restart Apache afterwards:

 sudo apachectl restart

Windows XP

Use the instructions at The Site Wizard

⚠️ **GitHub.com Fallback** ⚠️