WWW FAQs: How do I call a CGI script from a web page?

2005-07-20: If your web server supports both CGI and server side includes, then you can easily insert the output of a CGI script or program into a web page using server side includes. Use this syntax to insert the output of a CGI program located at the URL /cgi-bin/mycgi:

<!--#include virtual="/cgi-bin/mycgi"-->

Legal Note: yes, you may use sample HTML, Javascript, PHP and other code presented above in your own projects. You may not reproduce large portions of the text of the article without our express permission.

Got a LiveJournal account? Keep up with the latest articles in this FAQ by adding our syndicated feed to your friends list!