I’ve updated my “parameterdemo” to include a couple PHP pages. The latest trunk (0.8.1-dev) now supports PHP through the use of Quercus. To enable it simply set a context parameter in your web.xml and include the quercus and resin-utils jars in your WEB-INF/lib. See the zip file for a complete example (eclipse + ant).
Once you deploy the war, go to these urls to test (update your port to match your servers setting):
PHP example getting value from Red5 application:
<a href="http://localhost/parameterdemo/getparam.php">http://localhost/parameterdemo/getparam.php</a>
Same example with debug output:
<a href="http://localhost/parameterdemo/getparam.php?debug=true">http://localhost/parameterdemo/getparam.php?debug=true</a>
Java servlet example:
<a href="http://localhost/parameterdemo/myservlet">http://localhost/parameterdemo/myservlet</a>
The web.xml entry must look like so:
<context-param> <param-name>enable-php</param-name> <param-value>true</param-value> </context-param>
Tags: bean, Java, parameter, PHP, Red5, servlet