Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # App.pm:
- $r->route('/page/:id')
- ->name('page_show')
- ->to( controller => 'page', action => 'show' );
- # Page.pm:
- sub show {
- my $c = shift;
- warn 'has_data: '. $c->validation->has_data . ' id: ' . $c->param('id');
- ...
- }
- Request to "/page/99" prints:
- has_data: id: 1 at /home/dan/uc2/script/../lib/App/Page.pm line 26.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement