I want to call a java program and fetch it\'s output in stdout. I followed the suggestions in stackoverflow. But it doesn\'t work.
I have add the class file to my C
I would recommend using Java/PHP Bridge found here: http://php-java-bridge.sourceforge.net/pjb/ It's quite easy to install and works very well.
Also, I recommend using the following link to download it. (it's the same one as the link in downloads->documentation)
http://sourceforge.net/projects/php-java-bridge/files/Binary%20package/php-java-bridge_6.2.1/php-java-bridge_6.2.1_documentation.zip/download
The file is JavaBridge.war. You'll probably want to use Tomcat for the Java EE container. Once Tomcat is set up, you just put this file in the webapps folder and it's installed.
If you want to regularly use java classes in PHP this is the best method I know of and I have tried a lot of them. Resin also worked, but it didn't play nice with my mail server.