Total Novice, installed Apache, MySQL and PHP need HELP!

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
aljan
Forum Newbie
Posts: 4
Joined: Fri Feb 20, 2004 6:48 am

Total Novice, installed Apache, MySQL and PHP need HELP!

Post by aljan »

I'm a total novice to php but I have 4 years background in using html.

I've installed Apache on Windows and think I have correctly configured it to recognise PHP. I've also installed MySQL.
I've now worked out how to save a file in notepad with the .php file extension just to display my first "hello world" but can't get it to work.
What could I be doing wrong? Where should I save the php file in the first place or doesn't that matter?

I've been following the book "php for dummies" and I really feel like the biggest dummy of all right now. HELP. :cry:
User avatar
markl999
DevNet Resident
Posts: 1972
Joined: Thu Oct 16, 2003 5:49 pm
Location: Manchester (UK)

Post by markl999 »

If you look in c:\Program File\Apache2\Apache\conf (or wherever yours is) you'll see a file called httpd.conf, in there is a line starting with DocumentRoot.
Create a test file called test.php with just <?php phpinfo() ?> in it then goto http://localhost/test.php and see what happens. Do you see the php code, get a blank page, get a download prompt .. or does it work ok? ;)
aljan
Forum Newbie
Posts: 4
Joined: Fri Feb 20, 2004 6:48 am

Post by aljan »

I've found the line which say's
DocumentRoot "C:/Program Files/Apache Group/Apache/htdocs"

No do I change this or do I save my test file into the htdocs?
User avatar
ol4pr0
Forum Regular
Posts: 926
Joined: Thu Jan 08, 2004 11:22 am
Location: ecuador

Post by ol4pr0 »

Where did you put youre test.php ?
aljan
Forum Newbie
Posts: 4
Joined: Fri Feb 20, 2004 6:48 am

Post by aljan »

I put the test.php in the DocumentRoot "C:/Program Files/Apache Group/Apache/htdocs" and opened it in explorer but it didn't work
aljan
Forum Newbie
Posts: 4
Joined: Fri Feb 20, 2004 6:48 am

Post by aljan »

I created a test file called test.php with just <?php phpinfo() ?> in it and it came up with a blank page
Post Reply