1and1 Help Centre Categories

print article

How to display more than two product category levels in the product overview page

Even though you set the level of your product overview to more than 1, the product
overview on the shop only displays up to 1 sub category.
(eShop -> Advanced Settings -> Design -> Other settings for the shop design ->
Number of levels displayed in the product overview)
This is because the templates provided by the shop system contain product category
template files for only two levels(Main category and one sub-category). You will have
to create additional templates for additional levels.

First get the content of the file template_categorysub.template(eShop -> Shop design -> template_categorysub.template)
Create a new template file. Name it template_sub2.template. And paste the
content got from template_categorysub.templateThe code looks like this:


<tr>
<td>
<table border=0>
<tr>
<td width=25></td>
<td bgcolor="$global_color2_bright" valign=bottom colspan=1>
$font
<b>
<a href="<% URL_CATEGORY %>">$item_name</a>
</b>
$_font
</td>
</tr>
</table>
</td>
</tr>
Just introduce some spaces, so that the sub-category is indented in the product
overview page. So the final code will look as follows:

<tr>
<td>
<table border=0>
<tr>
<td width=25></td>
<td bgcolor="$global_color2_bright" valign=bottom colspan=1>
$font
 <b>
<a href="<% URL_CATEGORY %>">$item_name</a>
</b>
$_font
</td>
</tr>
</table>
</td>
</tr>
Note: So if you create template_sub3.template, add another space ( )

Now, you have to include this template in the product_overview.shopscriptfile. Open eShop -> Shop design -> product_overview.shopscript and add the code
highlighted in red.
[....]

<% SetTemplate("subgroup2","sub2") %>   

<% INIT_STRUCTURE %>
<html>
<head>
<title>$text_catalog_root_heading</title>
<% INCLUDE_VAR($CUSTOM_HEAD) %>
Important note: SetTemplate("subgroup2","sub2"), subgroup2 - should be let as
it is. sub2 - will be the file name of your new template without the prefix _template and .template