问题
I am using wamp server 2 and tomcat 7. I put javabridge.war inside webapp directorya and started tomcat. This created javabridge directory inside webapp.
I even copied this javabridge directory to the root directory. However, when I try to use the follwoing example, I get an error:
php require_once("java/Java.inc");
echo java("java.lang.System")->getProperties();
specified resource () has been forbidden.
Can someone tell me what mistake did i make in this setup?
回答1:
Remember to do all this
1. download PHP/Java Bridge(http://php-java-bridge.sourceforge.net/).
2. deploy the Java Bridge on tomcat Server.
3. copy the jar jasper lib, ireport lib and mysql connector j lib in tomcat lib folder
4. restart tomcat server
5. edit php.ini,turn on setting -> allow_url_include = On;
6. restart apache httpd server
来源:https://stackoverflow.com/questions/8160967/javabridge-setup-installation-issue