7 Replies Latest reply: Jan 7, 2013 1:33 AM by BCTemple RSS

    Hide content with {tag_instock, true}

    Spencer_wes Community Member

      Hi there,

       

      I need to show a form when an item is out of stock on the product details page. With the grouping function it was easy class="stockout-{tag_instock}" would call a class to hide ("stockout-1") or to display ("stockout-0").

       

      HOWEVER, with attributes you need to use the {tag_instock, true} tag which DOESN'T simply output a 0 or 1! It however outputs the number of stock items within <span> tags. This prevents me from using this css trick to show and hide content.

       

      eg: <span class="catInStock catInStock_6190581">0</span>

       

      I've explored various options ranging from jquery to content holders but nothing seems to work. If you could suggest anything I would be really grateful!

       

       

      Maybe a Json script?

       

       

      Kind regards,

      Wes