Quote:
Originally Posted by sinobest
If a category only has 1 product, how to let the category page redirect to the product page directly?
tks.
|
Hi.
Try to insert this to the /light_responsive/customer/home.tpl right after the opening <body> tag.
Code:
{if $main eq 'catalog' and $cat_products|@count eq 1}
<script type="text/javascript">
window.location.href = "{$cat_products[0].page_url}";
</script>
{/if}