Building a conpiler website

Scyere

Baseband Member
Messages
79
Can someone help me build a website that let's the user type C++ code into a text box, then when they press the compile button, it creates an .exe which it prompts then to download?
 
You'll probably just want to write a frontend to a compiler like MinGW in something like PHP.

Look into the exec() function in PHP. You could take the input from a text field, write it to a file with fopen() and fwrite(), then run system("gcc filename.c -o filename.exe") to compile the code. You could then provide a link to the output executable.

Of course, this is only a very rough guide!
 
Well,Hmm...An Exe ???Ok...Apparently In Dream Weaver You Can Include VBScript In HTML...What About this...
<html>
<head>
<script type="text/javascript">
A==prompt ("DOWNLOAD???y/n")
If A=="y"
 
Back
Top Bottom