kingston Well-known member Feb 10, 2011 #1 I want to add to an if statement that if not in a forum do this. I know its AND !{something} The forum idea is 123
I want to add to an if statement that if not in a forum do this. I know its AND !{something} The forum idea is 123
J James Well-known member Feb 10, 2011 #2 Depends on the template. Use {xen:helper dump $var} to see if node_id is available in that variable. If so, use: <xen:if is="$var.node_id != 123">do something</xen:if> Wow that took a while on my phone... Upvote 0 Downvote
Depends on the template. Use {xen:helper dump $var} to see if node_id is available in that variable. If so, use: <xen:if is="$var.node_id != 123">do something</xen:if> Wow that took a while on my phone...
Jake Bunce Well-known member Feb 10, 2011 #3 You forgot the curlies: Code: <xen:if is="{$var.node_id} != 123">do something</xen:if> As James said, it depends on the template. For example, edit this template: Admin CP -> Appearance -> Templates -> forum_view You can use this code in that template: Code: <xen:if is="{$forum.node_id} != 123">do something</xen:if> Upvote 0 Downvote
You forgot the curlies: Code: <xen:if is="{$var.node_id} != 123">do something</xen:if> As James said, it depends on the template. For example, edit this template: Admin CP -> Appearance -> Templates -> forum_view You can use this code in that template: Code: <xen:if is="{$forum.node_id} != 123">do something</xen:if>
J James Well-known member Feb 10, 2011 #4 Woops... I forgot the curlies! It was hard to type on my phone Upvote 0 Downvote