[Catalyst] RFC: Chained actions with PathPart('.')
Brian Kirkbride
brian.kirkbride at deeperbydesign.com
Thu Mar 22 19:23:43 GMT 2007
Brian Cassidy wrote:
> Perhaps you're looking for PathPrefix (coming to a new Catalyst near you
> ... eventually -- it's in svn now.). For now, do this:
>
> sub _parse_PathPrefix_attr {
> my ( $self, $c, $name, $value ) = @_;
> return PathPart => $self->path_prefix;
> }
>
> sub get_id : Chained('/') PathPrefix CaptureArgs(1) { }
>
> You can put the "_parse_PathPrefix_attr" sub in a base controller and
> all of your controllers will have access to it.
>
> -Brian
Cheers!
More information about the Catalyst
mailing list