|
|
CGI (Common Gateway Interface) is a means for web servers to communicate with other applications to get specialized information for the client. On the Macintosh, the web server uses an AppleEvent to send information about the client's request to the CGI. The CGI then does its custom processing and returns a result to the web server in the form of a reply to the AppleEvent. The web server then passes the result on to the client.
CGI is a synchronous protocol, ACGI is Asynchronous. What this means is that a CGI application ties up the web server until it is done (only applicable to non-threaded servers) and an ACGI lets the server carry on with responding to connections and returns its result to the server when it's done.
ACGI is usually preferable to CGI. Almost any application that can run as a CGI can run as an ACGI. Try switching your CGIs to ACGI, test them to see that they still work, then smile at the ease of this (not guaranteed for every program, but the vast majority work this way).
You need to use URL redirection. Your CGI should return a header as follows:
HTTP/1.0 302 Found
Location: URL
URL must be the complete (not partial or relative)
URL specifying the file the client should retrieve.
For example, returning the following HTTP header would cause the client to access
the URL "http://www.nisto.com/grant/":
HTTP/1.0 302 Found
Location: http://www.nisto.com/grant/
The $ gets translated to %24 with CERN HTTPd,
and the web server doesn't translate it back. This is because the CERN proxy
server is broken (this may be fixed in more recent versions).
As a possible solution, rewrite the CGI to check the url for '%24'
and convert it, or report it as a proxy server error.
There are two methods available:
|
|
|
|
|