cakephp links not relative
Posted
by Dan
on Stack Overflow
See other posts from Stack Overflow
or by Dan
Published on 2010-05-07T15:10:14Z
Indexed on
2010/05/07
18:08 UTC
Read the original article
Hit count: 139
In my layout, I have a menu that I've included as an element, and it contains a link like so..
<? $html->link('New Part Number','/part_numbers/add'); ?>
The problem that I have is that cake isn't redirecting correctly and it ends up sending me to "http://localhost/part_numbers/add" instead of "http://localhost/my_client_folder/client_app/part_numbers/add" (I'm building this locally). My cakephp app is stored a few directories below my webroot folder, but I thought cakephp would autodetect how to build the linking no matter where the application was located, right?
So do i need to configure the application root folder, or create a route or something?
Thanks!
© Stack Overflow or respective owner