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.

Archive /

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, biapar, Willr, Ingo, simon_w

Pulling data from DB to template


Reply


1156 Views

Avatar
hitautodestruct

Community Member, 19 Posts

28 January 2008 at 2:06am

Edited: 30/01/2008 12:04am

I know this should be super easy but I can't get my head about how to do this in the sapphire framework.

I have a control block:

<a href="<% control Level(1) %>$Prefix<% end_control %>SomePage">SomePage</a>


As you can see it simply goes to the top level page and gets the $Prefix field.
My question is how can I make a function that will do the same thing only with one template command. Something like:

<a href="{$WritePrefix}SomePage">SomePage</a>

Or better yet, is there a way to get the prefix from the top level and place it in every <a href=""> ?