Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: CGI and redirect

by comatose (Monk)
on May 24, 2000 at 17:31 UTC ( [id://14547]=note: print w/replies, xml ) Need Help??


in reply to CGI and redirect

You probably want to use the Location header as jjhorner described. Redirect does not work like it appears that you believe it to.

Redirect is for telling a browser that the site it was looking for has moved. Location is for redirects as most people think of them.

Replies are listed 'Best First'.
RE: Re: CGI and redirect
by mdillon (Priest) on May 24, 2000 at 21:27 UTC
    the "Location:" HTTP header is the only way to do a redirect with HTTP (and there's also its crappy META HTTP-EQUIV cousin but that's HTML). Location and Redirect are one and the same thing.

    as btrott says below, the real problem was that the header function was terminating the HTTP headers (by means of a blank line), before the redirect function was called, so the "Location: ..." header was interpreted by your browser (correctly) as the page body.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://14547]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (5)
As of 2024-04-24 08:06 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found