Magento - if category


/ Published in: PHP
Save to your folder(s)



Copy this code and paste it in your HTML
  1. <?php if (Mage::registry('current_category') && Mage::registry('current_category')->getId() == 7) : ?>
  2. <!-- if category # 7 - show this-->
  3. <?php else : ?>
  4. <!-- if not then show this-->
  5. <?php endif; ?>

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.