> This route, on the other hand:
> $Route->connect ('/who_we_are/*', array('controller' => 'pages',
> 'action' => 'index', 'who_we_are'));
> still matches /who_we_are/, but it also matches anything after it. The
> problem is, the two routes are effectively the same. All you're doing
> by passing 'who_we_are' as the default value is telling the router to
> pass that as the default value if no other value is specified.
> Unfortunately, you can't do both-and.
ahh, got ya, haev found a workaround, which seems to work fine, what
do you think?
function index ()
{
(!empty($args[0])) ? $category = $args[0]: $category = null;
(!empty($args[1])) ? $handle = $args[1]: $handle = null;
(!empty($args[2])) ? $subHandle = $args[2]: $subHandle = null;
}
I can then use the route below which works fine:
$Route->connect ('/who_we_are/*', array('controller' => 'pages',
'action' => 'index','who_we_are'));
hopefully should be easy to rework when 1.2 is out.
thanks,
jon
--
jon bennett
t: +44 (0) 1225 341 039 w: http://www.jben.net/
iChat (AIM): jbendotnet Skype: jon-bennett
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---