Page 1 of 1

[56K WARN] document root troubles

Posted: Sat Sep 30, 2006 11:33 am
by NiteShift
Hi guys/gals my name is Lee and I'm from Manchester England. I am a part time uni student and we are doing a module in Software engineering. I am currently looking through a few tutorials on PHP (that is waht we have to program in). The only problem is that I don't have any experience of PHP. I have downloaded WAMP5 but can't find any help files to get me started. I have saved a basic hello.php file in the www directory but yet when I type in http://localhost/hello.php I just get:

Not Found

The requested URL /hello.php was not found on this server.
Apache/2.0.59 (Win32) PHP/5.1.6 Server at localhost Port 80


I'm running Windows XP Home if that helps.

Thanks in advance,

Lee
[url=http://forums.devnetwork.net/viewtopic.php?t=30037]Forum Rules[/url] Section 1.1 wrote:2. Use descriptive subjects when you start a new thread. Vague titles such as "Help!", "Why?" are misleading and keep you from receiving an answer to your question.

Posted: Sat Sep 30, 2006 11:35 am
by Ambush Commander
Crack open your %Apache Install Folder%/conf/httpd.conf and tell me what DocumentRoot is set to (do a search of the file)

Posted: Sat Sep 30, 2006 11:36 am
by miro_igov
What is the physical path to your htdocs directory ?

Posted: Sat Sep 30, 2006 12:07 pm
by NiteShift
Image

I have opened the File titled Apache 2 and these ar the files it opens.....what do I need to do now?

Thanks

Posted: Sat Sep 30, 2006 12:17 pm
by Ambush Commander
Go to the httpd.conf file and search for "DocumentRoot" Give me that entire line.

Posted: Sat Sep 30, 2006 12:22 pm
by NiteShift
Ambush Commander wrote:Go to the httpd.conf file and search for "DocumentRoot" Give me that entire line.
When I click on it, it just searches for the best program to open it and if I right click on it there is no option to search it. :cry:

Posted: Sat Sep 30, 2006 12:23 pm
by Ambush Commander
Open it with Notepad. Then search.

Posted: Sat Sep 30, 2006 12:25 pm
by NiteShift
A ha!!! just found it......


DocumentRoot: The directory out of which you will serve your
# documents. By default, all requests are taken from this directory, but
# symbolic links and aliases may be used to point to other locations.
#
DocumentRoot "C:/wamp/www"

Posted: Sat Sep 30, 2006 12:26 pm
by Ambush Commander
Is that where you placed your file?

Posted: Sat Sep 30, 2006 12:28 pm
by NiteShift
Is that where I would save the hello.php file??

Posted: Sat Sep 30, 2006 12:30 pm
by Ambush Commander
Yes. You can change it to a more convenient place if you like, but by default that's where you'd put the goods.

Posted: Sat Sep 30, 2006 12:30 pm
by NiteShift
Just checked and it is in that file