How to run an application on a server from a web page

Example:

User login to the web page => Click the button

This action launches the "CreatePrettyPicture" executable.
The "prettypicture.jpg" file is created on the server.
When the user reloads the page, the page displays a pretty picture "PrettyPicture.jpg".

If I could run the app with a parameter it would be even better.

The server is Debian and I am using Apache as the web server. Please let me know if you need more information on the server configuration.

The ability for multiple users to press a button at the same time is not part of the problem.

+1


source to share


2 answers


You're better off using a server-side script with your apache installation to run the executable. It's probably easier with PHP (which should be easy to install if it doesn't already exist), here are the commands . As long as you don't actually use any input with the page, it should be reasonably secure.



+1


source


You need to read CGI Scripts .



It is also possible that PHP is already available on your server, but I would not recommend using it unless you are already familiar with it and do not know all the security issues that, due to the question, seem very unlikely.

+2


source







All Articles