I have a website. I’d like to do the following:
Have an input box that the user can type a java program. Then, they can press “Run” and it spits out standard output. How can I achieve this?
I tried thinking about using exec(“javac $filename”) in php and just compile and run the java program, but that doesn’t seem to be working. Any ideas?
I am trying to make a “learn Java” site, and I need the user to be able to play with code by typing into spaces on my website. I just can’t figure out how to go about running Java using php, html, or things like that.
1 Answer