View Single Post
  #2   IP: 192.240.127.74
Old 2016-02-14, 07:41 PM
Raelyn Raelyn is offline
初级会员
 
Join Date: 2006-01-02
Posts: 1
Raelyn 现在声名狼藉
Default

One small bug .... lets say you have one product and 5 subcategories, it will not show the subcategories because it automatically jumps to the one product. To fix it :
Code:
{if $products|@count eq 1} 
{if $subcategories}{else}
   {assign var="prodURL" value="product.php?productid=`$products.0.productid`&cat=$cat&page=1"} 
   {php} 
      header( "Location: " . $GLOBALS[smarty]->_tpl_vars[prodURL] ); 
   {/php} 
{/if}
{/if}
Reply With Quote