Thursday, May 27, 2010

Re: Prefix routing problem

that does not solve the problem...

Router::connect('/aktivieren', array('controller' => 'users', 'action'
=> 'activate', 'admin'=>false, 'prefix'=>false ));
Router::connect('/aktivieren/', array('controller' => 'users',
'action' => 'activate', 'admin'=>false, 'prefix'=>false ));
Router::connect('/aktivieren/*', array('controller' => 'users',
'action' => 'activate', 'admin'=>false, 'prefix'=>false ));


I tried all combinations and accessing
/aktivieren
/aktivieren/
/aktivieren/blabla


it ends up in "admin_activate" not "activate"

On 28 Mai, 06:24, Bogdan Bursuc <bogdanbursu...@gmail.com> wrote:
> You need to define the master route, also:
>
> Router::connect('/aktivieren/', ...); That's the router you access when you
> enter /aktivieren.
>
>
>
> On Fri, May 28, 2010 at 2:05 AM, cronet <cro...@gmx.de> wrote:
> > Hey,
>
> > i defined the following route:
>
> >        Router::connect('/aktivieren/*', array('controller' => 'users',
> > 'action' => 'activate', 'admin'=>false));
>
> > But everytime when I try to access /aktivieren cake routes me to
> > admin_activatie...
>
> > Here ar some vars from pr($this)
>
> >    [action] => admin_activate
> >    [uses] =>
> >    [params] => Array
> >        (
> >            [named] => Array
> >                (
> >                )
>
> >            [pass] => Array
> >                (
> >                )
>
> >            [controller] => users
> >            [action] => admin_activate
> >            [admin] =>
> >            [prefix] => admin
> >            [plugin] =>
> >            [form] => Array
> >                (
> >                )
>
> >            [url] => Array
> >                (
> >                    [url] => aktivieren
> >                )
>
> >        )
>
> > Why I get always to admin, even when i set admin=>false ?
>
> > Regards,
> > AxlF
>
> > Check out the new CakePHP Questions sitehttp://cakeqs.organd help others
> > with their CakePHP related questions.
>
> > You received this message because you are subscribed to the Google Groups
> > "CakePHP" group.
> > To post to this group, send email to cake-php@googlegroups.com
> > To unsubscribe from this group, send email to
> > cake-php+unsubscribe@googlegroups.com<cake-php%2Bunsubscribe@googlegroups.com>For more options, visit this group at
> >http://groups.google.com/group/cake-php?hl=en
>
> --
> Bogdan Iulian Bursuc

Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.

You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en

No comments: