* Alex Povolotsky [EMAIL PROTECTED] [2008-03-20 11:25]:
+sub uri_redirect {
+my ($c, $path) = @_;
+return $c-response-redirect($c-uri_for($path));
+}
But `uri_for` can take a lot more parameters than just one;
there’s no reason you have to restrict your utility methods
to the first
Hi Aristotle!
But `uri_for` can take a lot more parameters than just one;
there’s no reason you have to restrict your utility methods
to the first one.
Also, it would be handy to be able to pass the status parameter (i.e.
303 is widely used) to res-redirect() when using these utlity methods
On Thu, Mar 20, 2008 at 7:05 AM, Michele Beltrame [EMAIL PROTECTED] wrote:
Hi Aristotle!
But `uri_for` can take a lot more parameters than just one;
there's no reason you have to restrict your utility methods
to the first one.
Also, it would be handy to be able to pass the status
On Thu, Mar 20, 2008 at 8:36 AM, Matt Lawrence [EMAIL PROTECTED] wrote:
J. Shirley wrote:
On Thu, Mar 20, 2008 at 7:05 AM, Michele Beltrame [EMAIL PROTECTED]
wrote:
Hi Aristotle!
But `uri_for` can take a lot more parameters than just one;
there's no reason you have to
* J. Shirley [EMAIL PROTECTED] [2008-03-20 16:30]:
Something that sets the status to 303 if the request type is a
post (and HTTP 1.1 as Aristotle posted earlier, although I'm
not sure what the best way to check is. Assume it is unless
stated otherwise, or vice-versa?)
That’s pretty simple:
* Matt Lawrence [EMAIL PROTECTED] [2008-03-20 16:50]:
It would be cleaner, but less concise, to use a hash-like
configuration:
# Temporary redirect to /my/action/1/2/3?q=search%20string
$c-uri_redirect({
action = '/my/action',
args = [qw( 1 2 3 )],
status = 307,
query = { q =