The situation is different. Indeed there is no really mysite/admin/
the admin here is an action from pages controller. But there is admin
routs such as mysite/admin/users/add. What I need to achieve is to set
or make an index page for admin and when the user is being on mysite/
admin/users/add and has a redirect to be directed to a controller
without admin prefix as regarded before.

In more clearance, the problem is:
When the user becomes on some place like mysite/admin/posts and got a
redirect code, the action portion auto prefixed with admin.

The redirect code logic I uses is a method of AppController and it
called from beforeFilter function in AppController too.

On Jun 12, 3:50 am, Kurt Polinar <[email protected]> wrote:
> You can use either:  redirect('controller'=>'pages', 'action'=>'display',
> 'admin'=> true) or redirect('controller'=>'pages', 'action'=>'display',
> 'prefix'=>'admin')
>
> use 'prefix'=>'admin' or 'admin'=>true to redirect to admin pages.
>
> On Sat, Jun 12, 2010 at 5:06 AM, saidbakr <[email protected]> wrote:
> > In other word,
>
> > What does make something like  redirect('controller'=>'pages',
> > 'action'=>'display') perform redirection to missing action
> > "admin_display"?
>
> > On Jun 12, 12:03 am, saidbakr <[email protected]> wrote:
> > > Hi,
> > > Admin actions "admin_actionname()" works fine something like this:
>
> > >http://thesite.com/admin/contros/actionname
>
> > > What I need is to set another page to work as admin home to be
> > >  http://thesite.com/admin/
>
> > > I manged this from pages controller by setting an action called admin
> > > and set route to it, but this solution makes some trouble with
> > > redirects from admin actions to another non admin action using
> > $this->redirect('controller'=>'contNames', 'action'=>'actionname') because
>
> > > it redirect it pages controller but the action is admin_action where
> > > it is not found.
>
> > 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 [email protected]
> > To unsubscribe from this group, send email to
> > [email protected]<cake-php%[email protected]>For
> >  more options, visit this group at
> >http://groups.google.com/group/cake-php?hl=en

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 [email protected]
To unsubscribe from this group, send email to
[email protected] For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en

Reply via email to