I don't think that with the way controllers and routes work you can acheive what you want for all docs.  You would have to write a specific route for each page you want to display as /home, /otherpage, etc...

You could however rename your display() function to index() instead and have  /docs/home, /docs/otherpage.

Elsewhere in the group someone was also working on a URL hijack in bootstrap.php so the url would be /docs-home so that the url would use a hyphen rather than a backslash to improve search engine rankings for individual pages.

On 6/27/06, BlenderStyle <[EMAIL PROTECTED]> wrote:

Okay, I want to use a custom DocsController in place of
PagesController. So, in app/config/routes.php I did this:
$Route->connect('/', array('controller' => 'docs', 'action' =>
'display', 'home'));

That works fine with my display() method is my DocsController. However,
is there a way to change the address bar so that instead of
docs/display/home it's just /home? I read the API on routes but it
didn't help me much.



--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake PHP" 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
-~----------~----~----~----~------~----~------~--~---

Reply via email to