Archived

This topic is now archived and is closed to further replies.

running a c program in my website that is hosted by a linux server...

This topic is 5376 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

what are the necessary step/things i should do? my webhost supports PHP. i''m planning to use PHP, call on my program, is that possible? so how do you exactly compiled your program so it can run in linux? do i study the different kind of shells that linux has and compile to one of this? i have no idea, thanks,

Share this post


Link to post
Share on other sites
The safest way to do it would be to get telnet or SSH access from the server admin, and use that to invoke GCC. If you can''t do that, you could probably use one of the PHP exec functions to run GCC to compile your code on the server, but be warned that the admin might not like you doing that. If you have CGI support, you can use a .htaccess file to set .exe files to be treated as CGI and executed when requested. In that case, you wouldn''t need to use PHP to run your program.

Share this post


Link to post
Share on other sites