
October 17th, 2012, 07:19 AM
|
 |
Contributing User
|
|
|
|
|
Catalsy :Path vs :Local
I'm little conused over methods with the access modifier of ':Path'
I have a new controller and have this code (which is auto generated)
Code:
sub index :Path :Args(0) {
my ( $self, $c ) = @_;
$c->response->body('Matched Members::Controller::LibraryDocs in LibraryDocs.;
}
As I undestand the action mechanism, that should only run if the url is Quote: | http://mydomain/librarydocs |
and the root.pm 'index' should run if the URL is
Only now when the root url is accessed, the librarydocs method is running?
Why?
Edit->
infact I added a method in the librarydocs controller
Code:
sub test :Path :Args(0){
my ( $self, $c ) = @_;
$c->response->body('Matched HLP_Members::Controller::LibraryDocs test in LibraryDocs.);
}
which won't run if I use the url Quote: | http://mydomain/librarydocs/test | but does run for

Last edited by 1DMF : October 17th, 2012 at 07:29 AM.
|