I am working on an application where the same underlying code is used
for several slight variations on the theme. The 'instances' each share
the same db structure, but have different data sets and some small
configuration differences.

I have worked out a way of setting up different database
configurations using the URL, and have also worked out how to load a
customised config file for each instance, also based on the URL.

So I will have separate URLs for each app, all mapped to the same
controller:

 * /cake/apples is mapped to 'fruits' controller
 * /cake/pears is mapped to 'fruits' controller

        Router::connect('/apples/*', array('controller' => 'fruits',
'action' => 'index'));

When I link to /cake/fruits/edit/123 it all works fine

But when I link to /cake/apples/edit/123, I always get directed back
to the index.

Two questions:
1. What am I doung wrong in the routing to direct all traffic to
index?
2. Is there any way I can reset the name of the controller so all
internal links are to the correct path?


--~--~---------~--~----~------------~-------~--~----~
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