Brands Page

A page that shows a grid of all product brands that are available, including pagination. Clicking on a brand logo will take you to a category page that shows all items related to the brand.

Wireframe

Brands Page


Preparation Checklist

Before you start this tweak, it's a good idea to run through our preparation checklist below:

  • Read through the Getting Started Guide to get a better sense of how the Control Panel, Database and Front End store interact.
  • Learn our recommended Simple Workflow. This makes the implementation process as easy as possible.
  • Create a new Staging Theme for this tweak. This allows you to preview any changes before they are visible to live customers.
  • The code snippet in this tweak doc uses Bootstrap 4, you may need to alter this code depending on what version of Bootstrap your theme is using. You can find out what version your theme is using here.

Coding Instructions

Step 1: Create a brands template

Navigate to the folder /httpdocs/assets/themes/[THEME-NAME]/templates/cms/ and create a new template named brands.template.html.

Step 2: Add the code to the template

Paste the following code into the empty template:

[%load_template file:'cms/includes/sidebar.template.html'/%]
[%breadcrumb%]
    [%param *header%]
        <nav aria-label="breadcrumb">
            <ol class="breadcrumb" itemscope itemtype="http://schema.org/BreadcrumbList">
                <li class="breadcrumb-item" itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem">
                    <a href="[@config:home_url@]" itemprop="item"><span itemprop="name">Home</span></a>
                    <meta itemprop="position" content="0" />
                </li>
    [%/param%]
    [%param *body%]
                <li class="breadcrumb-item" itemprop="itemListElement" itemscope itemtype="http://schema.org/ListItem">
                    <a href="[@url@]" itemprop="item"><span itemprop="name">[@name@]</span></a>
                    <meta itemprop="position" content="[%calc [@count@] + 1 /%]" />
                </li>
    [%/param%]
    [%param *footer%]
            </ol>
        </nav>
    [%/param%]
[%/breadcrumb%]
<h1 class="display-4">[%url_info name:'page_heading' default:'[@content_name@]'/%]</h1>
[%if ![@form:pgnum@] OR [@form:pgnum@] eq '1'%]
    <section class="n-responsive-content" aria-label="Description">
        [%parse%]
            [@content_description1@]
            [@content_description2@]
            [@content_description3@]
            [@content_wufoo_form@]
        [%/parse%]
    </section>
[%/if%]
[%thumb_list type:'content' content_type:'brand' limit:'999' filter_category:'' sortby:'content_name'%]
    [%param *header%]
        <div class="row align-items-center">
    [%/param%]
    [%param *body%]
            <div class="brand-item mb-3 text-center col-6 col-md-4 col-lg-3">
                <a href="[@URL@]">
                    <img class="img-fluid" src="[%ASSET_URL type:'content' id:'[@content_id@]'%][%param default%][%cdn_asset html:'0' library:'images'%]default_product.gif[%/cdn_asset%][%/param%][%/ASSET_URL%]" alt="[@name@]"/>
                </a>
            </div>
    [%/param%]
    [%param *footer%]
        </div>
    [%/param%]
[%/thumb_list%]
</div>

Step 3: Create a brands page

Create an information page named Brands, and set the "Body Template" to brands.

Brands page template


Customising this Section

More information on how to customise this section can be found within the Thumb List Documentation.

Was this article useful?

Be notified when this page is updated. Optional.