Magento layered navigation category Url: Link Not Working

828 Views Asked by At

There is a code into filter.php file that is

<?php foreach ($this->getItems() as $_item): ?>
<li>
    <?php if ($_item->getCount() > 0): ?>
    <a href="<?php echo $this->urlEscape($_item->getUrl()) ?>"><?php echo $_item->getLabel() ?></a>
    <?php else: echo $_item->getLabel() ?>
    <?php endif; ?>
    <?php if ($this->shouldDisplayProductCount()): ?>
    (<?php echo $_item->getCount() ?>)
    <?php endif; ?>
</li>
<?php endforeach ?>

When category link is clicked it is taking to unspecified path mentioned below

localhost/flowershop/index.php/#%21cat=42 THIS CATEGORY IS COMING THROUGH getURL function but it is not taking anywhere

As compared to TOP Navigation, every link of Category/Subcategory going to correct path with URLkey html links as mentioned below

localhost/flowershop/index.php/funeral-flowers.html.

I have checked with re-write URL rules and as well as .htaccess file but nothing coming out to be good. Seeking for a perfect solution for this..

0

There are 0 best solutions below