Windows Installer for Current PHP version?
Posted 21 October 2006 - 03:48 AM
First problem... the PHP install docs talk about a basic Windows installer. But the only installer on the download page is for several releases back. Has phpMyAdmin abandoned the Windows installer for later releases?
I tried manual install using the instructions, and as far as I know, I got it all installed. But all phpMyAdmin commmands from Apache (and even a 1-liner test) gives me a 500 Server error.
So I simply went to the command line in the and typed php index.php. I get no output, and it simply returns to the command prompt. (I have another much older installation on another box. doing the same thing, I get a complete html dump of the page. So something is major different.
I can't find logs anywhere. I have no clue why it isn't working. The only difference between the older install and this one (other than versions) is that I used the now-non-existant Windows installer on the old install on the other box.
I'm pretty certain I've just got some magic config item that the installer does that I didn't do. I debug software for a living, and I'm pretty good at finding problems. But with no logs or any indication other than "it's broke" is making it very difficult.
So first of all, if I'm simply overlooking the current version windows installer, just direct me. If I'm stuck with manual config, can someone tell me what I've missed?
On the old-working box, I don't have a php.ini file. So I'm assuming that is not mandatory.
My steps on the current non-working install:
1) unzip php.zip into c:\php
2) unzip phpMyAdmin into the appropriate htdocs folder of apache
3) add c:\php to path in environment
4) tried adding the loadmodule php5Apache2.dll to httpd.conf until I read that it doesn't work with Apache 2.2. So changed back to the CGI config stuff in httpd.conf (pretty sure this works... same as on old box).
I've spent two days trying to get this to work. Nothing. This is frustrating. It shouldn't be this difficult.
What am I missing?
Posted 21 October 2006 - 11:35 AM
Install Apache 2.0.x instead.
Posted 21 October 2006 - 01:40 PM
What is the story with the missing Windows installer?
Posted 21 October 2006 - 01:50 PM
However the Windows Installer does nothing. All it does is extract the files from the installer to C:\php and thats it.
How are you installing Apache and PHP? When installing PHP have a read through this post of mine
Posted 21 October 2006 - 03:33 PM
But if it's just an unzip, it's obviously not my main problem. I have done the unzip manually. I have done everything in your post with one variation. I am indeed using Apache 2.2. But I had already discovered elsewhere that the module was not compatible. So I'm currently using the CGI-style configuration in httpd.conf:
ScriptAlias /php/ "c:/php/"
AddType application/x-httpd-php .php
Action application/x-httpd-php "/php/php.exe"
Is it that Apache 2.2 is completely incompatible or is it just the connector module that won't work. I would think there should be no problem with 2.2 if I was using the CGI version config above. It should be simply routing stdin / stdout, right?
I put the hello.php in my htdocs dir. I get a 500 error when I try to hit it from my browser. The apache error log has:
[Sat Oct 21 09:12:38 2006] [error] [client 127.0.0.1] Premature end of script headers: php.exe
is there any way to see some sort of logs for what PHP is trying to do? I can't find any logs other than the apache one-liner.
Posted 21 October 2006 - 04:13 PM
Installing PHP as an Apache module is easier. When you download the third part apache module you should be able to use PHP5.1.x with Apache2.2.x
I have no idea why theres no installer for PHP5.1.6. However I still do recommend you to downgrade Apache to Apache2.0.x though.
Posted 21 October 2006 - 04:24 PM
Sorry I deleted your last reply. Didnt mean that.
PHP can write error logs. In order to do that you need to tell it to. However PHP usually writes errors to Apaches error log (when loaded as an Apache Module/CGI successfully) and/or the sytems error log.
To make PHP write to an error log find and edit the php.ini in the php folder, or where ever you have it located to. If you cant find it the rename php.ini-recommended (in the php folder) to php.ini instead. Now edit the php.ini
Find where it says
display_startup_errors = Off
change Off to On
Now to make PHP write PHP to its own error log you need to find the following:
;error_log = filename
and change that to this:
error_log = "C:/php-errors.log"
Save the php.ini and copy the php.ini to C:\WINDOWS\. Restart Apache or attempt to run a script via the command line. It should report errors to the error log you just setup. Make sure php-errors.log exists in the root of your hard drive first though.
Posted 21 October 2006 - 05:17 PM
So it appears that apache is not able to invoke any exe file. So I'm off now to look at my apache config.
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users