Page loaded Blank

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
mchan
Forum Newbie
Posts: 1
Joined: Thu Jan 15, 2004 11:50 am

Page loaded Blank

Post by mchan »

Hi, I am very new in PHP, I installed Apache2 / Mysql / Php4 in Win2k server, when test the first script (<? phpinfo() ?> in the IE6, I got out put of the code instead of PHP info page.
I also tried the "Hello" test page, and the browser only loaded a blank page but the code is viewable from the source.
Can any one please help!
MC
User avatar
phpcoder
Forum Contributor
Posts: 158
Joined: Sat Nov 02, 2002 1:18 pm
Location: Manchester, UK

Post by phpcoder »

Check ur php.ini file .May b the tag <? ?> is off and also try with

Code: Select all

<?php
echo phpinfo();
?>
[/quote]
User avatar
infolock
DevNet Resident
Posts: 1708
Joined: Wed Sep 25, 2002 7:47 pm

Post by infolock »

there are 2 things that this could be. Either as phpcoder said you didn't setup your php.ini file correctly, or the other possibility ( and most likely ) you haven't installed php as a module on apache.

If you read the Install.txt file that is included with your php distribution ( i am assuming that you chose C:\php to be the home directory for your php script ), you will find installation instructions in the install.txt file for apache.

What you are gonna end up having to do is copy the correct php4apache.dll files into your %system_root% directory ( for win2k i think it's something like c:\winnt4\system32 or win2k\system32, sorry it's been a while since i used it .. ).

In any case, you are also going to have to open your conf file confiruation for apache.

A more thorough installation guide can be found on this URL :
http://www.onlygeeks.com/read/15

hope this helps. I'm not at home or i'd be able to give you some more indepth installation instructions, though the url i just gave you pretty much tells you step by step how to set your pc up for php.

let us know if you get it fixed, and if you have any more questions don't hesitate to ask.
timhortons
Forum Commoner
Posts: 29
Joined: Thu Jan 15, 2004 11:48 am
Location: Calgary, AB, Canada

Post by timhortons »

Hope i'm not condescending or anything, but Apache's "httpd.conf" file needs some editting in order for PHP to work... did you put in the lines that the PHP install told ya too?

If not, then it's the php.ini's short tag option.

It's most likely configuration problems. Make sure the paths are right, make sure the httpd.conf file for apache is setup right, and check out the php.ini file (make sure the php.ini file is in the right place on the machine too)

a second late, anyways, yeah, Apache and PHP come with pretty good install instructions, make sure you go through it step by step.
Post Reply