Home Ask Login Register

Developers Planet

Your answer is one click away!

Tracy February 2016

Need to run .exe file on iis server by php

I have developed .exe file to run some software automatically its working fine when i click on .exe file,now i want to run this file by php but i want to run this .exe file to run on server not on user pc. Please give me some suggestion if we can do this in php. I know this sounds like some weird question i need some help or suggestions from your side.Please let me know if this is not possible in php or i need some another language to make this script run in the way i want.

Thanks in advance :)


sudhakar February 2016

for more read this http://php.net/manual/en/function.exec.php

you can do it simply by exec(abc.exe)

SaucedApples February 2016

exec( 'file.exe', &$output);
echo $output;


If you are using shared hosting, you will need to check with your provider that they allow this.

You can also check if exec is allowed by creating a php file with the following code and then opening it in the browser after uploading it to the server.

if(function_exists('exec')) {
    echo "exec is enabled";

Post Status

Asked in February 2016
Viewed 1,436 times
Voted 14
Answered 2 times


Leave an answer

Quote of the day: live life