Knowledgebase: Site Design

How Do I Modify the Homepage Add to Cart Button To Direct a Customer to the Product Page?


This article will help you modify the add to cart buttons on your homepage so they always lead a customer to the product page, rather than the View Cart page:

The home page template can be found by going to Settings >Design >Themes & Styles and clicking on the "Edit Template (HTML)" button along the top right of the page.

This will take you to your currently installed Theme folder. If the home.html template is not present, then it can be found using the "Go to Folder" drop down located at the top right and selecting the templates/common-core or common-html5 folder (depending on the type of theme you are using).

For Core Themes

In the template, look for the block of coding found within the following start and end tags:

<!--START: addtocart-->

<--END: addtocart-->
  1. Change the coding in the block to the following:
<div class="action">
<a href="product.asp?itemid=[catalogid]" class="btn btn-default">
<span class="buyitlink-text">[category_buyitlink] </a>

For HTML5 Themes

Find the following section in the home.html template

<input type="button" value="[category_buyitlink]" onClick="window.location='add_cart.asp?quick=1&item_id=[catalogid]'" class="btn" onMouseOver="this.className='btn_over'" onMouseOut="this.className='btn'">

You will need to change this part:


To this:


Help Desk Software by Kayako fusion