Thread: Site map page
View Single Post
  #74  
Old 04-03-2007, 12:26 PM
 
medici medici is offline
 

Newbie
  
Join Date: Nov 2006
Posts: 2
 

Default Re: Site map page - Links

I can't figure out how to link the site map's text to the appropriate category/subcategory page. Any help would be appreciated.

HTML Code:
{* $Id: sitemap.tpl,v 1.00 2005/02/24 09:53:29 max Exp $ *} {include file="dialog.tpl" title="Site Map" content=$smarty.capture.sitemap extra="width=100%"} {capture name=sitemap} <ul type="square"> {*** start unordered list***} {section name=l1_cat_num loop=$allcategories} {*** loop ALL categories ***} {if $allcategories[l1_cat_num].parentid eq 0} {*** loop root categories/parentid 0 - level 1***} <li> {$allcategories[l1_cat_num].category} {if $allcategories[l1_cat_num].subcategory_count gt 0} {*** check if root cat has child cats ***} <ul type="square"> {section name=l2_cat_num loop=$allcategories} {*** loop through sub cats with matching parent id ***} {if $allcategories[l2_cat_num].parentid eq $allcategories[l1_cat_num].categoryid} <li> {$allcategories[l2_cat_num].category} {if $allcategories[l2_cat_num].subcategory_count gt 0} {*** check if parent has child cats***} <ul type="square"> {section name=l3_cat_num loop=$allcategories} {if $allcategories[l3_cat_num].parentid eq $allcategories[l2_cat_num].categoryid} <li> {$allcategories[l3_cat_num].category} {if $allcategories[l3_cat_num].subcategory_count gt 0} {*** check if parent has child cats***} <ul> {section name=l4_cat_num loop=$allcategories} {if $allcategories[l4_cat_num].parentid eq $allcategories[l3_cat_num].categoryid} <li> {$allcategories[l4_cat_num].category} {/if}{/section}</ul> {/if}{/if}{/section}</ul> {/if}{/if}{/section}</ul> {/if}{/if}{/section}</ul> {/capture}
__________________
x-cart gold 4.0.5
Reply With Quote