I try to run an jar from an php file like this:
exec("java -jar /home/florinbuda/NetBeansProjects/monkey1/dist/monkey1.jar", $result);
print_r($result);
and IT WORKS if I run it from command line like:
$ php runner.php
but it doesn't work if I try to load it via http-localhost-server/runner.php the page just keeps loading forever without giving any error..
In the .jar file I added a simple test to now if the jar is even started to work
public static void main(String[] args) {
new File("/home/florinbuda/Desktop/xxx").mkdir();
and as you can guess - when I call http-localhost-server/runner.php the jar is not even started to be executed...
It's a problem of rights? What suggestions do you have?