X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Auto Display Sub-Categories under the Root Categories Menu (https://forum.x-cart.com/showthread.php?t=33769)

shopccp 09-07-2007 09:20 PM

Auto Display Sub-Categories under the Root Categories Menu
 
Does anyone know the smarty (database) code to display the subcategories under the categories menu as shown in my hor_categories.tpl?

The php code for the categories menu is shown in red. The section for the subcategories is shown in orange.

If anyone knows the database code to display the subcategories I would greatly appreicate it.


Code:

{* $Id: hor_categories.tpl,v 1.4.3.2 2007/05/12 12:15:08 max Exp $ *}

{**** Horizontal categories ****}
<script type="text/javascript">
{literal}
function hcCheckCategories() {}
{/literal}
</script>

{assign var="columns_num" value=#ColumnsInHM#}

<div class="pdmenu">
<ul>
<!-- CSS Tabs -->
{foreach from=$categories item="category" name="h_categories" key="key"}
{math equation="x+1" x=$hc_counter|default:"0" assign="hc_counter"}
{if $hc_counter <= $columns_num }

<li><a href="home.php?cat={$category.categoryid}" class="hcLink"><span>{$category.category}</span></a>
<ul>
<li><a href="" class="hcLink"><span></span></a></li>
</ul>

</li>

{if $smarty.foreach.h_categories.last && !$js_enabled}
{assign var="fit_all" value="Y"}
{/if}
{/if}
{/foreach}
{if !$fit_all }


Thanks for any help on this.

balinor 09-08-2007 03:28 AM

Re: Auto Display Sub-Categories under the Root Categories Menu
 
Have you had a look in the Custom Mods forum? Lots of mods to display sub-categories.


All times are GMT -8. The time now is 11:01 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.