I have the problem that the recently viewed products block only appear when I'm in one of my sub-categories and not in my parent category. I haven't worked with Magento before, so I don't know where to look. I did however find product_viewed.phtml, but it doesn't look like there is anything in the file, that defines that it should only be showed in sub-categories. Where else should i look? Below is my product_viewed.phtml file.

<?php if ($_products = $this->getRecentlyViewedProducts()): ?>
<div class="block block-list block-viewed">
    <div class="block-title">
        <strong><span><?php echo $this->__('Recently Viewed Products') ?></span></strong>
    <div class="block-content">
        <ol id="recently-viewed-items">
        <?php foreach ($_products as $_item): ?>
            <li class="item">
                <p class="product-name"><a href="<?php echo $this->getProductUrl($_item) ?>"><?php echo $this->helper('catalog/output')->productAttribute($_item, $_item->getName() , 'name') ?></a></p>
        <?php endforeach; ?>
        <script type="text/javascript">decorateList('recently-viewed-items');</script>
<?php endif; ?>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.