I am trying to add a LAMP Web Server by following the instructions at "http://www.howtogeek.com/howto/42480/how-to-turn-your-home-ubuntu-pc-into-a-lamp-web-server/"
I ran the following command:
sudo apt-get install lamp-server^
Everything seemed to install okay.
Testing of Apache worked fine using the localhost check
Next, I tried to test PHP by creating the file
sudo nano /var/www/testing.php <?php phpinfo(); ?>
I checked to make sure the file is located in the following directory:
I then restarted Apache with the following command:
sudo service apache2 restart
Next I tried to load the following page in my web browser:
I receive the following error message:
Not Found - The requested URL /testing.php was not found on this server. - Apache/2.4.18 (Ubuntu) Server at localhost Port 80
I checked to make sure PHP installed correctly using the following command:
~$ php --version
PHP 7.0.13-0ubuntu0.16.04.1 (cli) ( NTS ) Copyright (c) 1997-2016 The PHP Group Zend Engine v3.0.0, Copyright (c) 1998-2016 Zend Technologies with Zend OPcache v7.0.13-0ubuntu0.16.04.1, Copyright (c) 1999-2016, by Zend Technologies
Any ideas why I can not access testing php file, and why I am getting the 404 not found error message?