View Single Post
  #26  
Old 02-14-2005, 02:34 PM
 
mpj mpj is offline
 

Senior Member
  
Join Date: Feb 2005
Posts: 106
 

Default

hi Steve!

I'm trying to implement this code with your script. This would keep the current subcategory listed.

It's not my code, I got it from someone on this forum. Sorry I dont remember the original thread.

HTH.

Thanks for your kind reply.


Code:
{section name=cat_num loop=$categories} {* Added by Fernando. Show first level of subcategories *} {if $current_category ne "" } {section name=subcat loop=$allcategories} {assign var=topmostcat value=$allcategories[subcat].categoryid_path|regex_replace:"/\/.*/":""} {assign var=current_category_top value=$current_category.categoryid_path|regex_replace:"/\/.*/":""} {if $current_category_top eq $topmostcat and $categories[cat_num].categoryid eq $topmostcat and $allcategories[subcat].parentid eq $topmostcat and $allcategories[subcat].categoryid ne $current_category_top} {$allcategories[subcat].category|truncate:20:"...":true} {/if} {/section} {/if} {* End added by Fernando *} {/section}
__________________
X-Cart 4.0.11


{My simple mods}
Adding Market list and % save on product detail
Quantity input box
Reply With Quote