hi guys,
Does anyone know how i can adjust the categories view.tpl so i can show subcategories from child categories?
I.E
Root level category page shows:
CATEGORY CATEGORY
within those categories you have
SUB CATEGORY SUB CATEGORY
SUB CATEGORY SUB CATEGORY
SUB CATEGORY SUB CATEGORY
SUB CATEGORY SUB CATEGORY
SUB CATEGORY SUB CATEGORY
SUB CATEGORY SUB CATEGORY
However the root level category of course just shows on the view sub category (1st level) then you click through and then shows the child sub categories but anyway to adjust the view so that i can also show the sub categories from the subcategory if that makes sense?
If you go here: http://2015.ambientlounge.com/interior/
You cannot see but shows the 2 sub categories which are:
http://2015.ambientlounge.com/interior/gold-class-bean-bags/
and
http://2015.ambientlounge.com/interior/bean-bags/
looking at those pages your see i have nice images for their sub categories but want to display those also in root level on the interior page… so in stead of just showing gold glass category and bean bags category i want to also show the sub-categories from those as well.
Hope that makes sense!
```php
{hook name=“categories:view”}
{if $category_data.description || $runtime.customization_mode.live_editor}
{/if}
{if $subcategories}
{math equation="ceil(n/c)" assign="rows" n=$subcategories|count c=$columns|default:"2"}
{split data=$subcategories size=$rows assign="splitted_subcategories"}
-
{if $category.main_pair}
{include file="common/image.tpl"
show_detailed_link=false
images=$category.main_pair
no_ids=true
image_id="category_image"
image_width=$settings.Thumbnails.category_lists_thumbnail_width
image_height=$settings.Thumbnails.category_lists_thumbnail_height
class="ty-subcategories-img"
}
{/if}
{foreach from=$splitted_subcategories item="ssubcateg"}
{foreach from=$ssubcateg item=category name="ssubcateg"}
{if $category}
{/if}
{/foreach}
{/foreach}
{/if}
{if $products}
{assign var="layouts" value=""|fn_get_products_views:false:0}
{if $category_data.product_columns}
{assign var="product_columns" value=$category_data.product_columns}
{else}
{assign var="product_columns" value=$settings.Appearance.columns_in_products_list}
{/if}
{if $layouts.$selected_layout.template}
{include file="`$layouts.$selected_layout.template`" columns=$product_columns}
{/if}
{elseif !$subcategories || $show_no_products_block}
{__("text_no_products")}
{else}
{/if}
{capture name="mainbox_title"}{$category_data.category}{/capture}
{/hook}
```