In the example below we set up the assets as in Assign Asset Attribute to a Variable and Output to Screen and assign them to the output variable named pageID.
In the second section we are calling the render:calltemplate tag to render the template you specify. The template we are calling in this example is /SideNavTopLinks the / is used to denote a Typeless template. Most Templates used will be without the / and so will be Typed templates. We feed the pageID var into the cid attribute of the render:calltemplate tag.
In the example below we close the tag but it is also possible to use a self-closing tag e.g.
<render:calltemplate..... /> or
<render:calltemplate ...></render:calltemplate>. In this example I am rendering a MenuLink which is an arrribute of my Asset. I am using the tempate called myLinks to display this asset.
<assetset:setasset name="pageMenuAsset" type="MenuLink" id="<%=ics.GetVar("MenuListID")%>"/> <assetset:getattributevalues name="pageMenuAsset" typename="Ass" attribute="MenuLinkPage" listvarname="MenuLinkPageList"/> <ics:listget listname="MenuLinkPageList" fieldname="value" output="pageID" /> <render:calltemplate tname="/myLinks" site="<%=ics.GetVar("site")%>" tid="<%=ics.GetVar("tid")%>" slotname="myLinkSlot" c="Page" cid="<%=ics.GetVar("pageID")%>" ttype="Template" context=""> </render:calltemplate>
I hope you found this useful or if you have any questions don't hesitate to leave a comment or contact support[@]tomred[.]net
This what I have spent most of my time working in over the years and these are the little bits of logic or snippets I have come across. Some of these are things I have needed to search for or I have found I needed to feedback on code reviews.
During my time working in consulting I was tasked many times with delivering FatWire sites. I took notes due to the lack of useful documentation at the time. These are the results of those notes made and shared.
I believe the majority of time on a project is spent with the UI. Web is no exception. I have compiled a set of articles covering HTML, CSS and JS with the intention of taking the sting out of this work.
A space dedicated to all those things you need to know beyond writing code. This covers Linux, Windows, Git and SVN among other hopefully useful nuggets.
I picked up some pointers over the years consulting for government and banking sectors before entering a PCI DSS development environment. This section covers aspects like coding, testing, code review and best practice.
Apps is a section which offers access to bits and pieces I have put together over the last few years. This includes Random Password Generator and Base64 Encoder.