* Dennis Daupert <ddaup...@gmail.com> [2010-01-08 17:50]:
> I've tried various incarnations of go, but here's one:
>
>     my @args = qw( $user_id  $blog_id );

Uhm, you know that `qw` does not interpolate, right? So that line
will assign the literal strings '$user_id' and '$blog_id' into
@args, not the contents of the variables $user_id and $blog_id.
That would be why your IDs are invalid… just basic Perl stuff,
nothing to do with Catalyst.

>     my @captures = $c->req->captures;
>
>     $c->go( 'Blog::Controller::User::Blog::Entry', 'list', [ \...@captures,
> \...@args ] );
>
> I also tried with my @captures = (), @captures =  qw( $user_id  $blog_id );
>
> I don't see go yet.

The square brackets in the POD (which I think they are a really
bad stylistic choice there) mean that these arguments are
optional, not that you should pass those parameters inside an
anonymous array. I think you are looking for

    my @caps = ( $user_id, $blog_id );
    $c->go( '/user/blog/entry/list', \...@caps );

or just

    $c->go( '/user/blog/entry/list', [ $user_id, $blog_id ] );

Regards,
-- 
Aristotle Pagaltzis // <http://plasmasturm.org/>

_______________________________________________
List: Catalyst@lists.scsys.co.uk
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
Dev site: http://dev.catalyst.perl.org/

Reply via email to