Install PHP
Install the PHP
...
Packages
Code Block | ||
---|---|---|
| ||
sudo apt-get install php5 |
As of Ubuntu 12 (an maybe even earlier), the installer will automatically restart Apache2 for you.
Verify
Quickly verify that everything works by creating a php info file with your favourite editor,
...
Save the file and browser to file using a browser. You can use either the IP Address or the valid Domain Name. For example, http://173.194.75.94/info.php or http://www.krypton.com/info.php which should show a purple and grey PHP informational screen.
Secure the Server
suPHP, LiteSpeed Web Server
Install MySQL
Code Block | ||
---|---|---|
| ||
sudo apt-get install mysql-server |
For the root administration database password, use the standard password algorithm based on the server name.
Connect PHP to MySQL
Code Block | ||
---|---|---|
| ||
sudo apt-get install php5-mysql |
FAQ
Why do some of the php5 installations say to use install libapache2-mod-php5?
...