View Full Version : a few questions...
Martin
Sat 22nd Apr '00, 9:38am
I noticed that PHP must be set up to run as CGI, not ISAPI, so that question is answered for me.
We are about to start setting up our server to run it.
I have downloaded the latest PHP4 RC1 for NT 4.0, I have the latest Zend Beta 2.
I noticed in the installation instructions it said to set it as such:
ScriptAlias /php3/ "c:/path/to/php/"
AddType application/x-httpd-php3 .php
Action application/x-httpd-php3 "/php3/php.exe"
would this change to:
ScriptAlias /php3/ "c:/path/to/php/"
AddType application/x-httpd-php4 .php
Action application/x-httpd-php4 "/php4/php.exe"
since I'm installing PHP4?
Are there any other tricks I need to know when setting this up? This is a brand new, raw NT 4.0 server.
Also, just for comparison specs, my server is a dual PIII 600 with 512Mb 100 SDRAM. What are we running on here?
Lastly, does it really run that much faster with the Zend Optimizer?
Thanx in advance :)
Herb
Sat 22nd Apr '00, 10:18am
heya martin,
I am running IIS here so I did not have to do what you have to.. I haven't played with PHP on Apache NT.. Is it apache your running?
I set my box up to parse both .php3 and .php I have had no problems running as a cgi but a bunch running as ISAPI..
Zend claims a huge increase.. With my toy boxes I really can't tell a difference since it is all local..
The live site I plan to use this software on is running Dual PII 450's w/512k and a 1/2 gig memory.. I can't imagine this not being enough..
John
Sat 22nd Apr '00, 10:41am
If it is Apache you are running, you have pretty well got it.
Try this:
ScriptAlias /php4/ "c:/path/to/php4/"
AddType application/x-httpd-php4 .php
Action application/x-httpd-php4 "/php4/php.exe"
That should get it going.
John
Martin
Sat 22nd Apr '00, 11:02am
exposing more of my ignorance here, but how do I set it up under IIS to run CGI instead of ISAPI?
Herb
Sat 22nd Apr '00, 11:00pm
Copy libmySQL.dll, php.exe, php.ini, and php4ts.dll to the \winnt or winnt\system32 directory.. either one will work.. I copied mine to \winnt..
Edit the php.ini as per instructions..
I am assuming your running IIS 4.0..
Open IIS.. Go to the website that you want to use PHP.. right click and choose properties.. Go tot he Home Dir Tab and near the bottom click on the configuration button..
Under the AppMapping tab you will see ext that ISS will parse.. Choose add.. For executable the path would be c:\winnt\php.exe %s %s or c:\winnt\system32\php.exe %s %s
for extension use .php, Method eclusion left blank, script engine checked and check fle exists unchecked.. Click ok and apply.. To add another ext like .php3 repeat the last few steps..
Now go to the directory that PHP will run in and click its properties and allow Execute includin script in the permissions..
create a php file called test.php and add <? phpinfo(); ?>
If all went well you will see a bunch of info about php..
Hope this helps..
Martin
Fri 5th May '00, 7:43pm
I followed the instructions to the letter. (I think)
I copied all the DLL's to the winnt\system32 folder (except the phpisapi.dll)
I went to the domain that it's going to run in, set the php and php3 extensions up.
This is what I get with the test file:
PHP: Unable to parse configuration file.
I don't understand what you meant by:
Now go to the directory that PHP will run in and click its properties and allow Execute includin script in the permissions..
the only place I can find to set permissions for "Execute(including script)" is on the Home Directory tab. Is that the radio button I'm sposed to set?
I appreciate your help and patience :)
Martin
Fri 5th May '00, 8:37pm
if any other NT experts want to jump in and tell me where I may be screwing up, please let me know :)
one more question:
Should I have set the phpisapi.dll in the ISAPI filters even though I'm not going going to be using it as ISAPI in this case?
Also, is it possible to run it as ISAPI under one domain and as CGI in a second?
Thanx :)
John
Fri 5th May '00, 10:05pm
Make sure that there is a php.ini in the PHP binary directory - this is what I needed for PHP3. Also, try putting the php.ini file in the windows directory.
John
Martin
Fri 5th May '00, 10:08pm
PHP binary directory?
there wasn't anything about a binary directory in the install instructions
John
Fri 5th May '00, 11:15pm
Oh - that must just have been php3 then. I think that the problem that PHP is having is that it cannot find a php.ini file. There should have been one called php.ini_dist or something like that in the download. That should be renames to php.ini and copied to the windows directory I think.
John
Martin
Fri 5th May '00, 11:22pm
it's sitting there right next to php.exe
I didn't change anything in it (I haven't installed Zend yet)...
This is getting aggravating. I appreciate your patience:)
vbsquare
Sat 6th May '00, 3:45am
OK. To set up PHP on IIS 4 do the following:
Simply right click on your web site in mmc and select properties. Add php as an ISAPI filter and to the Configuration bits under the Home Directory tab. Place the php.ini file in your c:\winnt directory. To get things working i didn't need to edit any values in the ini file. Everything should work ok from there onwards.
Powered by vBulletin™ Version 4.0.0 Beta 4 Copyright © 2009 vBulletin Solutions, Inc. All rights