Using version 1.3 and can report now that all is working perfectly as
expected so sorry for misleading anyone. After some fiddling, I can't
pinpoint what I did, but it's obvious it was an error I'd made
somewhere as cake is working as expected.

Sorry all.


On Apr 10, 3:13 am, Miles J <[email protected]> wrote:
> @Cricket - Thats how its done in 1.3.
>
> @Signified - Everything you said is correct and should happen, I use
> it all the time. Im actually quite lost as why thats not working, it
> looks correct. Try this:
>
> Router::connect('/login/*', array('controller' => 'users', 'action' =>
> 'login'));
>
> On Apr 9, 4:23 am, cricket <[email protected]> wrote:
>
>
>
> > On Apr 8, 8:39 pm, Signified <[email protected]> wrote:
>
> > > If I create this route:
>
> > > Router::connect('/login', array('controller' => 'users', 'action' =>
> > > 'login'));
>
> > > Then I use theHtmlHelperto create a hyperlink in a view like this:
>
> > > echo $this->Html->link('Login', array('controller' => 'users',
> > > 'action' => 'login'));
>
> > > I would expect to get this:
>
> > > <a href="/login">Login</a>
>
> > > But instead, I get this:
>
> > > <a href="/users/login">Login</a>
>
> > > Shouldn't theHtmlHelperhonour routes?
>
> > > If it did, I could change the route to be this (for whatever reason):
>
> > > Router::connect('/sign-in', array('controller' => 'users', 'action' =>
> > > 'login'));
>
> > > And all my links would update automagically.
>
> > > Any thoughts???
>
> > That's correct. The only thing I see that's different from how I do it
> > is that I use $html->link(...). I just tried it with $this->Html-
>
> > >link(...) and got a fatal error. Where do you have this code?
>
> > What version are you using?

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

To unsubscribe, reply using "remove me" as the subject.

Reply via email to