Hi all,

I decided to learn PHP, I am an Ubuntu user, I installed, php5, mysql, apache2.2 and phpmyadmin. But I don't know where to put the files to see them on my web browser, when I write


I get

Not Found

The requested URL /phpMyAdmin/ was not found on this server.
Apache/2.2.8 (Ubuntu) PHP/5.2.4-2ubuntu5.6 with Suhosin-Patch Server at localhost Port 80

Or when I try to put files into var/www, I get permission denied, Can anyone tell me what to do?


9 Years
Discussion Span
Last Post by Tulsa

Open terminal (Programs > System > Terminal or something like that)
type in 'su' (This command makes u a 'super user' so you can do anything)
Type in your root password (You should have set this when you install)
now type this command
chmod -R 775 /var/www/
then type
chown apache
chgrp apache

Then add yourself to the webserver group:
useradd -G {apache} YOURUSERNAMEHERE

now type exit twice and navigate to/var/www/html/
Right click > create new file
name it test.html and save it (It doesn't need any content its just to check that it works)
now navigate to http://localhost/test.html and see if that works
Sam Rudge
This will change the permisions so that Apache can read and write


If installation is not successfully than you need to install xampp pack after uninstaliing all of this right.
xampp pack is installed php,mysql and apachi automatically.
you should download xampp for windows from the this http://www.apachefriends.org site ok.

you must save all your php file in the httpdocs folder.
this folder you can find in the php instalation directory

than you can call your php file in the browser like


or if you have create a folder in the httpdocs directory and saved file there

If you want to leanr php from begining than you should download phpmanual help file from the php.net site


This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.