Jump to content

PHP code not showing


Recommended Posts

I'm not new to the php programming language by any means, but this is my first time installing PHP and Apache.

I'm working with Windows XP. I downloaded Apache2.2.3 and it is working fine, but after installing PHP5.2.0, I tried to view a PHP file (date display page) and all it gave me was a blank screen. To be specific... shows everything EXCEPT the php.

For example, the script
[i]<html>
<head>
<title>Testing PHP</title>
</head>
<body>

<? print(Date("l F d, Y")); ?>

Hopefully this works<p>
This is frustrating!

</body>
</html>[/i]
displays

[i]Hopefully this works

This is frustrating! [/i]

As for installing PHP and Apache...
I added C:\php; to the value of the PATH environment variable.
I also added the following to the httpd.conf file:

[i]LoadModule php5_module "c:/php/php5apache2_2.dll"
AddType application/x-httpd-php .php

# configure the path to php.ini
PHPIniDir "c:/php"

[/i]

Finally, i changed the php.ini-recommended file to simply php.ini and changed extension_dir to "C:\php\ext"

Is this correct and is there anything i neglected to change?

I'm not sure if it helps at all, but when I open the Apache monitor, the dev5_ap1 will not start... it says it can't find the path specified.
I've double-checked the code over and over and can't seem to find anything wrong...

Thanks
Link to comment
https://forums.phpfreaks.com/topic/33709-php-code-not-showing/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.