I've researched the archive and the common concensus for a CGI to perform redirection is:
However, I have not been able to get this to work with either Netscape 4.6 or Internet Explorer 4.0. Netscape returns a dialogbox with the message "The document contained no data". IE returns a dialogbox with the message "The server returned an invalid or unrecognized response".
I'm trying to develop a general purpose CGI in C++ that uses an argument from the input string to determine the destination CGI. The overriding reason is to "disable" the browser Back button. However, I'm first trying to get something to work with a fixed URL. The code (redirect.exe) for that is as follows:
main(int argc, char** argv)
cout << "Location: http://www.halcyon.com/msbinder/links/\r\n\r\n
The URL is my Home Page so I know it exists.
I'm calling the CGI from a start up page with the following URL:
"><font size="4"><strong>Start Up (Redirect CGI)</strong></font></a>
'boss7_man' is a Personal Web Server from MS Visual Studio; my development environment.
I've already tested a static page redirection (<meta http-equiv ...>) and that works with the browsers I'm using.