I just re-installed my Mint system and now I can't get php to work. I've tested apache and it seems to be working just fine, entering localhost into the URL brings up that default page in /var/www/ but when I created a small php file called testphp.php with nothing but phpinfo() function between to opening and closing braces all I get from the browser is NOT FOUND The requested URL /testphp.php was not found on this server. Any ideas what might have changed? After re-installing all I did was enter sudo apt-get install apache2 and sudo apt-get install php5
lewashby
56
Junior Poster
Recommended Answers
Jump to PostCheck the ownership and the permissions of the script, by writing the file into
/var/www/
you probably used sudo, correct? That gaveroot:root
to the script. Apache needs access to read and execute the file, so you can switch the group to www-data:sudo chown …
Jump to PostCheck the settings of
/etc/apache2/sites-available/default
or in apache2.conf and adjust the DocumentRoot to your desired path, then reload apache.
All 8 Replies
cereal
1,524
Nearly a Senior Poster
Featured Poster
lewashby
56
Junior Poster
cereal
1,524
Nearly a Senior Poster
Featured Poster
lewashby
56
Junior Poster
cereal
1,524
Nearly a Senior Poster
Featured Poster
AndrisP
193
Posting Pro in Training
AndrisP
193
Posting Pro in Training
lewashby
56
Junior Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.