not deemed the most appropriate by some but it works:
http://github.com/AD7six/mi_development/blob/master/vendors/shells/templates/skel/app_error.php#L98
However what you could do is have a variable with the name of the top
level pages and page folders (if you have any) and therefore define
(as your first route):
Router::connect('/:page/*',
array('controller'=>'pages', 'action' => 'display'),
array('action' => 'contact|faq|tos|stuff')
);
On May 28, 4:49 pm, Jon Bennett <jmbenn...@gmail.com> wrote:
> >> The above route is equivalent to the default route - i.e. it's the
> >> same as not having it defined (incidentally what are your admin_*
> >> functions doing defined like that?¿? - you're disabling the automatic
> >> admin/prefix protection by doing that.)
>
> I have been doing that since Nate suggested it back in 2008,
I'd be amazed if Nate ever suggested doing that.
Possibly:
//1.2 styley
Router::connect('/articles/:action',
array('controller'=>'articles', 'admin' => true, 'prefix' =>
'admin'),
array('action' => 'add|edit|index|delete|status')
);
OR
//1.3 styley
Router::connect('/articles/:action',
array('controller'=>'articles', 'prefix' => 'admin'),
array('action' => 'add|edit|index|delete|status')
);
(why route none-admin actions to admin actions, and always use admin_
as a prefix instead of just defining function index() ... ;) )
hth,
AD
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:
Post a Comment