I have a PHP web application developed using symfony framework. I want to call some Java code from within my PHP pages. Java code is distributed to multiple jar files and there is o开发者_C百科ne interface available to access the functionality. The input and outputs of the Java interface are XML files, text files, Java beans and some more complex objects.
Is there any bridge available in PHP to call complex Java methods or some other solution to this problem. Alternatively, I have to write soap web services to solve this problem.
You may want to look at these:
- Zend Platform Java Bridge
- PHP/Java Bridge
HTH
you could run the java code by exec or shell_exec ex.
shell_exec("java whatever.jar $parameter1 $parameter2");
Webservices would be the nicer solution though. IMO
精彩评论