How to open a HTML file when the python cgi program is executing?

Ken ken at hotmail.com
Sat Jun 1 14:28:34 CEST 2002


> If you realize this before you've output anything, you can use one of the
> redirection / refresh headers, such as "Location".
>
> print """Content-type: text/html
> Location: http://replacement-url
>
> <p><a href="http://replacement-url">Click here</a></p>

Doesn't seem to work... :(


> """
>
> Theoretically it should be sufficient to just give the Location, but put
in
> a human-readable redirection just in case.
>
> Otherwise, if you've already started, you must continue. Just open the
file
> and print it.
>
>
> As for frames, there's the main document, which decides which frames get
> shown; and then the server gets separate requests for each of the frames.
> You might want to browse a few pages with telnet to get a feel for how
> things work.

Where can I find this document?

Thanks





More information about the Python-list mailing list