Hi, sorry for bringing up a super old thread.
I'm using this for showing ads in my ad_above_top_breadcrumb, works fine. Then I wanted to randomize some ads, and it works fine for this rule: <xen:if is="{$forum.node_id} == 'number of forum'">
But I get a syntax error when I try to put my randomize code in <xen:if is="{$contentTemplate} == 'forum_list'">
The randomize code is like this:
<xen:if is="{$contentTemplate} == ’forum_list’”>
<xen:set var="$banners.1"><a href="ad1.php" target="_blank"><img src="ad1.jpg" width="100%" alt="ad 1"></a></xen:set>
<xen:set var="$banners.2"><a href="ad2.php" target="_blank"><img src="ad2.jpg" width="100%" alt="ad 2"></a></xen:set>
{xen:raw '$banners.{xen:calc '({$serverTime} % 2) + 1'}'}
</xen:if>
View attachment 150892
Is there another way to solve this? Putting my randomize ads on the first/main page - the forum list that is.