Beefy Boxes and Bandwidth Generously Provided by pair Networks Cowboy Neal with Hat
Just another Perl shrine
 
PerlMonks  

Re: Re: Re: CGI::Application design strategy

by larsen (Parson)
on Mar 02, 2004 at 11:12 UTC ( [id://333292]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to Re: Re: CGI::Application design strategy
in thread CGI::Application design strategy

The answer is yes. My actual code is pretty similar to yours.
sub build_redirect { my ($self, $form, $script) = @_; $form ||= {}; + my $q = $self->query; my $uri = URI->new( $script || $q->script_name ); + $uri->query_form(%$form); + return $uri->as_string; } sub redirect { my $self = shift; + $self->header_add( -uri => $self->build_redirect( @_ ) ); + $self->header_type('redirect'); + }

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://333292]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.