Developer forum

Forum » Templates » Itempublisher if statements

Itempublisher if statements

Regin Madsen
Reply

Hi,

Im having an Itempublisher listing items with an itemlist field.

Isnt it possible to do an if statement on those fields? or in that loop? seems like im never entering the "if" part

<!--@LoopStart(ItemPublisher:Items.List)-->

<!--@LoopStart(ItemPublisher:Item.ProduktLink)--><br/>
<!--@If('mytitel'<contains>ItemPublisher:Item.ProduktLink.Itemlink.Titel)-->
This is the: <!--@ItemPublisher:Item.ProduktLink.Itemlink.Titel-->
<!--@EndIf-->

<!--@LoopEnd(ItemPublisher:Item.ProduktLink)-->

<!--@LoopEnd(ItemPublisher:Items.List)-->


Replies

 
Mikkel Ricky
Reply

Try swapping 'mytitel' and ItemPublisher:Item.ProduktLink.Itemlink.Titel, i.e. write

<!--@If(ItemPublisher:Item.ProduktLink.Itemlink.Titel<contains>'mytitel')-->

(cf. the documentation [http://templates.dynamicweb-cms.com/TemplateTags/Dynamicweb-template-tags/General-tags/If-statements.aspx])

Best regards,
Mikkel

 

 

 

You must be logged in to post in the forum