For Programmers: Free Programming Magazines  


Home > Archive > PHP Installation > January 2007 > Newbie help - getting PHP 5.2.0 to work with Apache 2.2.4 on Windows Server 2003









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Newbie help - getting PHP 5.2.0 to work with Apache 2.2.4 on Windows Server 2003
Bryan Garmon

2007-01-26, 7:00 pm

I'm pulling my hair out trying to figure out what is wrong with my web
server configuration.

This is a new server build with with no previous PHP or apache installations
on the server.

I'm downloaded and installed apache 2.2.4 then downloaded the PHP 5.2.0 Zip
Package Windows Binaries from http://us3.php.net/downloads.php

I followed step by step the manual installation process for PHP 5.2.0 using
the installation instructions found here:

http://us3.php.net/manual/en/install.windows.manual.php

then being new to .php I visited:
http://www.php.net/manual/en/tutorial.firstpage.php

When I try to open the .PHP file referenced in example 1, directly on the
server using
Internet Explorer 7, the IE file download wizard dialog box pops up and
prompts me to either "open or save" the file, I choose "open," and instead
of opening, the same dialog box pops back up. It's an infinite loop until I
choose cancel.

Why is IE 7 not able to open the file?

So I installed Firefox 2 on the server and the php example file loads
properly.

So PHP is working right? I'm not quite sure. So I follow Example 2-2:

<?php phpinfo(); ?>

The behavior is the same in IE7 with the dialog box just looping, but in
Firefox I end up with a blank screen trying to load the phpinfo.

So Looking at the PHP FAQ
http://us3.php.net/manual/en/faq.in...ion.blankscreen

It tells me something is wrong with the server configuration (not exactly
helpful).

Apache appears to be fine as my website that is hosted on it is loading
fine. The website currently does not use PHP at all.

When I look at the error.log file for apache, each time the server is
restarted I see the following entry:

[notice] Apache/2.2.4 (Win32) PHP/5.2.0 configured -- resuming normal
operations

Does this mean PHP is working? I just don't understand what's not
functioning that is preventing the phpinfo command from running.

I added 3 lines to the apache httpd.conf file which are:

LoadModule php5_module "c:/php/php5apache2_2.dll"
AddType application/x-httpd-php .php
PHPIniDir c:/php/

I also added c:\php to the PATH Windows System Variable, and I also added a
new system variable called PHPRC and it references c:\php

Any help or suggestions for fixing these problems would be greatly
appreciated.
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com