Hi,

Correct way to implement above route would be:

Router::connectNamed(array('community_id'));
Router::connect('/:community_id/bulletins/:action/*',
array('controller' => 'bulletins'), array('community_id' =>
'[0-9]+'));

On Sep 10, 10:40 pm, "[EMAIL PROTECTED]"
<[EMAIL PROTECTED]> wrote:
> I have been working all morning on this without any luck. This is on
> Cake 1.2 (branch) / 5626. The only nonstandard thing I'm doing is app
> and webroot dirs outside the normal locations (and renamed), but that
> shouldn't make a difference with this.
>
> ROUTE
> $Route->connect('/:community_id/bulletins/:action/*',
> array('controller' => 'bulletins'));
>
> CONTROLLER/VIEW
> echo $html->url(array('community_id'=>203, 'controller'=>'bulletins',
> 'action'=>'view', 'bulletin_id'=>23423));
>
> EXPECTED URL:
> /203/bulletins/view/bulletin_id:23423
>
> RETURNED URL:
> /bulletins/view
>
> MODIFICATION (bulletin_id param removed)
> echo $html->url(array('community_id'=>203, 'controller'=>'bulletins',
> 'action'=>'view'));
>
> RETURNED URL:
> /203/bulletins/view


--~--~---------~--~----~------------~-------~--~----~
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?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to