I am having a bit of mental block... is something like this possible? in the browser /foo/bar/?a=blah&b=bork and in the applications get '/foo/:page' => sub { my $page = params->{page}; my $a = params->{a}; my $b = params->{b}; .. } I keep on getting the "void" message. If I change the uri to /foo/bar?a=blah&b=bork (note, the missing trailing / after bar) then the browser itself barfs saying the file wasn't found. -- Puneet Kishor
On Sat, Dec 11, 2010 at 11:21 PM, Puneet Kishor <punk.kish@gmail.com> wrote:
I am having a bit of mental block... is something like this possible?
in the browser /foo/bar/?a=blah&b=bork
and in the applications
get '/foo/:page' => sub { my $page = params->{page}; my $a = params->{a}; my $b = params->{b}; .. }
I keep on getting the "void" message. If I change the uri to
/foo/bar?a=blah&b=bork (note, the missing trailing / after bar)
then the browser itself barfs saying the file wasn't found.
-- Puneet Kishor _______________________________________________ Dancer-users mailing list Dancer-users@perldancer.org http://www.backup-manager.org/cgi-bin/listinfo/dancer-users
This will do what you want: get '/foo/:page/' => sub { } If you need something more fancy, you can use regex routes: get qr{/foo/([^/]+)/?} => sub { } -Naveed Massjouni
participants (2)
-
Naveed Massjouni -
Puneet Kishor