Our Product Stars widget allows you to display your product’s star rating on your website’s category page, catalogue page, search results page and/or collection page. The widget can be placed within a grid template or product template and will not go on the typical product theme.
This widget only works for PRODUCT reviews.
SKU Code:
The code snippets for the Product Stars integration for Product SKU is the below:
<script type="text/javascript" src="https://api.feefo.com/api/javascript/MERCHANTID" async></script>
<div class="feefo-product-stars-widget" data-product-sku="SKU"></div>
Parent SKU Code:
The code snippets for the Product Stars integration for Parent Product SKU is the below:
<script type="text/javascript" src="https://api.feefo.com/api/javascript/MERCHANTID" async></script>
<div class="feefo-product-stars-widget" data-parent-product-sku="PARENTSKU"></div>
NOTE: If using both Product SKU and Parent Product SKU, it will default to the Product SKU. If no results are found, it will default to Parent Product SKU.
The fields SKU and PARENTSKU, although optional, will need to be dynamic and therefore replaced with the relevant dynamic Product ID variable for a store CMS.
SHOPIFY Sample:
For Shopify the code snippet will typically need to be saved under a theme called product-card-grid.liquid. The code will use the variants below:
SKU Code:
The code snippets for the Product Stars integration for Product SKU is the below:
<script type="text/javascript" src="https://api.feefo.com/api/javascript/MERCHANTID" async></script>
<div class="feefo-product-stars-widget" data-product-sku="{{product.variants.first.sku}}"></div>
Parent SKU Code:
The code snippets for the Product Stars integration for Parent Product SKU is the below:
<script type="text/javascript" src="https://api.feefo.com/api/javascript/MERCHANTID" async></script>
<div class="feefo-product-stars-widget" data-parent-product-sku="{{product.id}}"></div>