Category Add to Cart

A category/subcategory grid ordering loop lets you loop through all the SKUs tied to a particular category or subcategory.

Grid Ordering On a Category/Subcategory Page:

{% loop category_grid_order %}
    <li>
        <a href="{category_grid_order.product_url}">
        {% if category_grid_order.product_image_small_url == '' %}
            <img class="th" src="{theme_location}/images/300x300.gif" />
        {% else %}
            <img class="th" src="{category_grid_order.product_image_small_url}" />
        {% endif %}
        </a>
        <div class="row">
            <div class="small-12 columns">
            {% if category_grid_order.has_variations %}
                Has Variations
            {% else %}
                {category_grid_order.product_quantity_html}
                {category_grid_order.ajax_id}
            {% endif %}
            </div>
        </div>
        <div class="row">
            <div class="small-8 columns">
                <h5 class="left"><a href="{category_grid_order.product_url}">{category_grid_order.product_name}</a></h5>
            </div>
            <div class="small-4 columns">
                <h5 class="right">{category_grid_order.product_price}</h5>
            </div>
       </div>
    </li>
{% ENDLOOP category_grid_order %}

Grid Ordering Loops can be called :

  • {% loop category_grid_order %}

The following output tags are available for a category/subcategory Grid Ordering Loop (Only available on a category or subcategory page):

{product_name}Product Display Name
{product_available_count}Page Slug
{product_price}SKU Price (not product price)
{product_variation}The variations tied to the product. This is a comma delimited string.
{product_quantity_html}
HTML input field for changing quantity
{product_sku}SKU
{ajax_id}Hidden Input field For {ajax_product_grid}
{attribute slug}All sku attribute slugs that have been flagged to show externally
Loop ConditionalsClick here to learn more about loop conditionals.



Start your free, no-risk trial today.