[ back to toc ]

call gi scripts from html code

Date: 2002/03/11 11:53

my question is farely simple.
i want to know how do you execute cgi or perl scripts or rather call them
from within html code.
i was told you need to use ExecCGI but i need to know the complete syntax
and also any other ways to do it.
i use apache web server 1.3 and am able to execute the perl script
separately without any problems.
Thanx in advance.
You do not evenneed an HTML page to start a CGI program. The only thing is
that the URL that the browser tries to open is served by a CGI program.
This means that the Apache server that you have should be configured to
treat certain directories as CGI directories and start the files as
external processes whenever they are referenced by an URL.

Thanx for the reply.
as u mentioned i am able to call the cgi program from the url.
but i need this cgi to be executed as part of the html page.
ie this is a counter and it needs to be shown along with other parts in
the html.
thats why i was wondering how do i execute this cgi from within the html.
please send an answer for the same.
Thanx again

This is something that you can do with server side include. If your server
does not support server side include then you have to alter your total
approach in a way that you do not display an HTML page, but start a CGI
program that itself prints out the whole HTML page including the counter.

For more information on the server side include syntax consult the
documentation ofg the web server. This is different on each server and not
standardized. Even may depend on the installation and configuration of the
actual server.


[ back to toc ]