Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: CGI Redirect with Status

by sutch (Curate)
on Jun 04, 2003 at 20:41 UTC ( #263143=note: print w/ replies, xml ) Need Help??


in reply to CGI Redirect with Status

Try it!

This:

#!/usr/bin/perl -Tw use CGI qw(:standard); my $cgi = new CGI; print redirect('http://perlmonks.org/');
Results in:
bash-2.05$ ./test.pl Status: 302 Moved Location: http://perlmonks.org/ bash-2.05$


Comment on Re: CGI Redirect with Status
Select or Download Code
Re: Re: CGI Redirect with Status
by Ovid (Cardinal) on Jun 04, 2003 at 21:01 UTC

    Your results show his problem. He wants a 301 status code (moved permanently), not a 302 status code (Found). See status code definitions for more information.

    Cheers,
    Ovid

    New address of my CGI Course.
    Silence is Evil (feel free to copy and distribute widely - note copyright text)

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (5)
As of 2014-07-31 00:25 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (241 votes), past polls