java - Executing a command in terminal using php -


i trying run external command via php. want compile java file. i've tried this , this. unfortunately, in case java file doesn't compiling.

what wrong in code ?

exec("javac main.java"); 

but when compiled manually, , execute follwing command, works fine.

exec("java main"); 


Comments

Popular posts from this blog

javascript - How to synchronize the Three.js and HTML/SVG coordinate systems (especially w.r.t. the y-axis)? -

javascript - How do I find how many occurences are there of a highlighted string, and which occurence is it? -

java - Reading data from multiple zip files and combining them to one -