The two templates
Both files are in the shop’s TopRank directory. The shop system first looks for a subshop-specific version with the subshop identifier appended, for example
template-category-deutsch.htm. Only if it does not find one does it use the general file. This lets you design individual subshops separately without touching the others.Placeholders are written as in the shop template, that is,
~Name~ for a value, {Name} and {/Name} for an area and {@Name} and {/@Name} for a loop.Shop details
These placeholders are freely available in both templates.StartUrl and URL-Template exist in the shop system but are not described in the previous documentation. StartUrl is the more useful of the two, because it lets you build the way back to the TopRank overview on every category page.ShopID and SubshopID are suitable for tracking scripts that should also run on the static pages.The category page
Everything in this section applies exclusively intemplate-category.htm.
The displayed category
CatDescr() shortens to the number of characters specified in parentheses and removes all HTML markup in the process. This is intentional, because otherwise cutting off in the middle of the text would leave an open element without its closing counterpart. This is the right version for the description entry in the page header.CatPage, CatPage-1 and CatShortDescr exist in the shop system but are not described in the previous documentation. CatPage-1 is the missing half of Catname-1, because without the file name you cannot build a link from the name of the parent category.Keywords is generated by the shop system and contains the name of the category as well as the names of up to three parent categories. If there are fewer, the shop system fills up with fixed terms. The word from ShopKeyword is always included.The five free fields per category are maintained in the TopRank Manager and hold up to 4000 characters. They can be used as a value and as an area; the area applies if the field is filled.
The products of the category
{Products} is the area that only appears if the category contains products. {@Products} is the loop over them.
PrdDescr exists in the shop system but is not described in the previous documentation. It returns the full description of the product including HTML markup.PrdShortDescr uses the maintained short description. If it is missing, the shop system instead shortens the full description to about 150 characters. The spot therefore only remains empty if both fields are empty.Not every product in the category ends up on the page. Products that are not visible at the time of generation and products of the autobasket category are skipped. The previous documentation does not mention this.
Paging with many products
The number of products per page is limited in the TopRank configuration. If a category has more, the shop system distributes them across several files.If the category fits on one page,
Splitlinks remains empty. Therefore, place the paging navigation in a bracketing, otherwise short pages will contain an empty element.The subcategories
This section applies in both templates. On the overview page, you use it to loop over the top-level categories; on a category page, over its subcategories.SCatName is not simply the category name but the search term stored in the TopRank Manager, if one is maintained there. Only otherwise does the shop system fall back on the category name.SCatDescr() shortens and removes HTML markup in the process, just like CatDescr() at category level.The overview page
Two placeholders exist only intemplate-subshop.htm.
ShopDescr exists in the shop system but is not described in the previous documentation. It is the counterpart to CatDescr on the category page and usually belongs in the description entry in the page header of the overview.CreateDate contains date and time in the format TT.MM.JJJJ HH:MM:SS. The value comes from the moment of generation, not from the page call. On a static page, this is exactly the sensible value.Placeholders at a glance
The “Placed in” column names the loop within which the placeholder must be placed. Anything marked “free” may be placed anywhere in the respective template.
Related topics
- Guide: Customising templates for TopRank
- Guide: SEO optimisation with TopRank
- Guide: SEO URLs
- Reference: SEO- (TopRank URL settings)
