Download the FastCGI enabled Sun Java System Web Server 7.0 PHP Add-On 1.0 from: http://www.sun.com/download/index.jsp
Configure PHP as a FastCGI server on Web Server.
Unpack the phppack-5_2_0*.zip to /export/home
$ cd /export/home; unzip phppack-5_2_0*.zip |
Start the Administration Server.
$ <webserver-install-root>/admin-server/bin/startserv |
Configure the FastCGI handler using Administration Console.
Login to the Administration Console.
Click Edit Virtual Server from Virtual Server Tasks.
Under Virtual Server General Properties, click the Content Handling tab.
Under Content Handling — General Properties, click the FastCGI tab.
Click New to add a new URI with FastCGI handler mapping.
Enter the following values:
Applies To: Select New URI and enter /fastcgi/*
Role: Select Responder from the drop-down list.
Application Path: Enter /export/home/php/bin/php as the path.
Environment Variables: Enter the variable:
"PHPRC=/export/home/php","LD_LIBRARY_PATH=/export/home/php", "LD_LIBRARY_PATH_64=/export/home/php/64" |
Click OK. Click Deploy if needed.
Create a symbolic link.
$ ln -s <webserver-install-root>/samples/fastcgi <webserver-instance-docroot> |
Run the samples.
Hello World sample URL
http://<host-name>:<webserver-instance-port>/fastcgi/HelloWorld.php
Directory Listing sample URL
http://<host-name>:<webserver-instance-port>/fastcgi/directory.php
Page Counter sample URL
http://<host-name>:<webserver-instance-port>/fastcgi/pageCounter.php
Server Information sample URL
http://<host-name>:<webserver-instance-port>/fastcgi/serverinfo.php