Conditional Statements

Conditional Statements

@Brogan - Is it possible to write a conditional statement that will display my ad in the initial forum node view. See image below for example of what I'm trying to do. Also, is it possible to place this ad in the Category bar with a conditional statement as well? Thank you.

forum-view.webp
 
That doesn't involve a conditional statement.
It would be done using CSS utilising the node ID.
 
It's out of scope for this resource so you would be better off posting a new thread in the styling forum.
 
Hi Brogan,

I'd like to hide the avatars from the Recent Posts list (placed in the sidebar), would you know which conditional I should use?

Thank you!
 
You would have to ask in the resource thread for recent posts in the sidebar as that is not XF default functionality.

It would only be a template edit anyway, not a conditional statement.
 
How can I show content after thread x on every page in a thread list? (For example while listing topics in a specific forum or listing new topics) :D
 
OK, I've been told by Adsense to remove ads on my thread id 34998.

Whatever I do though it displays, so I'm asking for help.

Some members view adsense banners and some view rotating image banners. that works fine. In summary...
PHP:
<xen:comment> PLACE YOUR ADVERTISEMENT CODE DIRECTLY BELOW </xen:comment>

<xen:if is="{xen:helper ismemberof, $visitor, 22,23,4,5,3,32,29}">

ROATATING IMAGE CODE FOR FULL MEMBERS

<xen:else />

ADSENSE CODE FOR EVERYONE ELSE

</xen:if>

<xen:comment> PLACE YOUR ADVERTISEMENT CODE DIRECTLY ABOVE</xen:comment>

What I can't work out is how to NOT show the adsense in thread 34998.

Could anyone help please?
 
That's the thing, it isn't recognising the thread ID at all.

Code:
<xen:comment> PLACE YOUR ADVERTISEMENT CODE DIRECTLY BELOW </xen:comment>
<xen:if is="{$thread.thread_id} != 34998">
<xen:if is="{xen:helper ismemberof, $visitor, 22,23,4,5,3,32,29}">

ROATATING IMAGE CODE FOR FULL MEMBERS

<xen:else />

ADSENSE CODE FOR EVERYONE ELSE

</xen:if>
</xen:if>

<xen:comment> PLACE YOUR ADVERTISEMENT CODE DIRECTLY ABOVE</xen:comment>

Doesn't work, exactly the same.
 
Top Bottom