Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We're retiring the forums!

The SilverStripe forums have passed their heyday. They'll stick around, but will be read only. We'd encourage you to get involved in the community via the following channels instead:

Template Questions /

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

Hardcoding a part of the Navigation


Go to End


3 Posts   1158 Views

Avatar
baba-papa

Community Member, 279 Posts

15 October 2009 at 3:26am

Hi,

due to my page layout I am forced to hardcode some of my navigation links:

$BaseHref/contact/

This leads to the following output: www.mysite//contact
It works but it looks bad. Is there another way to hardcode navigation links?

Avatar
Willr

Forum Moderator, 5523 Posts

15 October 2009 at 1:47pm

$BaseHref includes a / (hence why you get 2 //) Just write it as {$BaseHref}contact.

Avatar
baba-papa

Community Member, 279 Posts

15 October 2009 at 5:14pm

Thanks, willr.