0

I am new to php and i have a question: Is it possible to start a jar file from php?

Have you ever heard of a way to accomplish?

Thy only way i know is the

exec()

or

shell_exec()

function.

Abdulla Nilam
  • 36,589
  • 17
  • 64
  • 85
NoRelect
  • 598
  • 4
  • 20
  • http://stackoverflow.com/questions/17596237/how-to-run-a-jar-from-a-web-server-using-php or http://stackoverflow.com/questions/16766464/how-to-call-an-executable-jar-from-php-with-an-argument-passed-to-main-method ? – trainoasis Jul 13 '15 at 07:16
  • What is missing in `exec()` and `shell_exec()` for your requirement ? – Ali Jul 13 '15 at 07:22

1 Answers1

1

shell_exec returns all of the output stream as a string.

shell_exec()

exec returns the last line of the output.

exec()

And duplicate of php shell_exec() vs exec()

Community
  • 1
  • 1
Abdulla Nilam
  • 36,589
  • 17
  • 64
  • 85