[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


Hahaha.  Sorry, that was one hairy problem.
Oh, John or someone, perhaps you can explain why step 13 is necessary.  I
had to test each one, until I found the bare number of lines to rem out.

Here's how to install and use php3 with pi3web.

Open up the config.pi3 or whichever file you are using
1) Find the "Handlers" line in the "HTTPDispatcherClass" Object.  I hope
you only have one
2) In that line add "PHP3Scripts".  I added it right after "Scripts"  But
anywhere is pretty much okay.
3)Now find the Object w/ Name "Scripts" and Class
"FlexibleClassHandlerClass".  Make a copy of everything between "<Object>"
and "</Object>"
4)Change the Name line from "Scripts" to "PHP3Scripts"
5)The third line is something like:
Condition "&cmp(&dblookup(response,string,ObjectMap),Scripts)"
At the very end, change it to "PHP3Scripts" instead of "Scripts"
6)The last line is something like:
Handle StandardCGI
Change that to say
Handle PHP3CGI
7)Locate the Object w/ Name "StandardCGI" and Class "CGIClass"
8)Make a copy of everything between "<Object>" and "</Object>"
9)Change the Name line from "StandardCGI" to "PHP3CGI"
10)Change the DefaultCommand Line to:
	DefaultCommandLine "m:/php3/php.exe %p%q"
Replacing "m:/php3/" with whereever your php3 is located.
11)Erase all CommandLineByExt lines.
12)Add the following line in their place:
	CommandLineByExt .php3="m:/php3/php.exe %p%q"
13)Now, there's a series of Variable lines.  Put a "#" in front of these
#	Variable "REQUEST_METHOD=$m"
#	Variable "SERVER_NAME=$v"
14)Now go find the following line
Mapping FCGIMapper From="/cgi-fcgi/" To="p:\web\m31\cgi-fcgi\"
and the following line, replacing the directories with what you want.
Mapping PHP3Mapper From="/cgi-php3/" To="p:\web\m31\cgi-php3\" 

Wow.  Just restart the server, and you are done.
If you are recieving a message about unable to parse the ini file, take the
php3.ini-dist file and copy it as php3.ini into your windows directory.