Product Badges (Deprecated)
This documentation covers our pre August 2020 implementation. We strongly recommend upgrading to our latest JavaScript implementation to take advantage of performance improvements and additional features. Our migration guide can be found here.
To display the product badge on your website you have to
- Include the Reevoo JavaScript library
- Add the
reevoo-reviewable-badge
tag withtrkref="TRKREF"
andSKU="SKU"
TRKREF
should be replaced with your unique account codeSKU
needs to be dynamically replaced with the corresponding product SKU
Example

<reevoo-reviewable-badge
trkref="TRKREF"
sku="SKU"
></reevoo-reviewable-badge>
Badge variants
You can also specify the badge variant name. It can be useful
for different types of pages like category listing or search result.
Example

<reevoo-reviewable-badge
trkref="TRKREF"
sku="SKU"
variant="variant_name"
></reevoo-reviewable-badge>
variant_name
needs to be replaced with the badge variant, supplied by Reevoo
Product Badges for Branches
When rendering a product badge you can specify the branch-code that the customer experience tab should be limited to.
This is useful when you do not want to show all CEX reviews.
Note: If you try to render a badge with a code we do not have, the badge will not render. You will need to provide use with new branch codes if this is the case.
Example
<reevoo-reviewable-badge
trkref="TRKREF"
sku="SKU"
branch-code="branch_code"
></reevoo-reviewable-badge>
branch_code
needs to be replaced with the branch code you supplied to Reevoo
Product Badges for Product Groups
Instead of using SKU of a particular product you can use product group identifier
<reevoo-reviewable-badge
trkref="TRKREF"
sku="series:group_identifier"
></reevoo-reviewable-badge>
group_identifier
needs to be replaced with the product group identifier
Product Badges for Automotive Partners
Our automotive partners which have been enabled to use Automotive Aggregation, can display the product badges based on automotive metadata instead of a "sku".
The automotive metadata includes attributes like manufacturer
, model
, model-year
, and many others. The full list of available attributes correspond to the values in our automotive product feed specification.
To display product badges based on automotive metadata, add the reevoo-reviewable-badge
tag with attributes trkref="TRKREF
, and then any combination of automotive metadata attributes. See some examples below.
NOTE: Please use hyphen ('-') separator for each HTML attribute to stick with HTML conventions, for example model-year
. This can be seen in the examples below.
Examples
Minimal required attributes are trkref
, manufacturer
and model
:
<reevoo-reviewable-badge
trkref="TRKREF"
manufacturer="ford"
model="fiesta"
></reevoo-reviewable-badge>
We strongly recommend using more specific parameters such as model-year
, body-type
, etc to get more relevant scores. Speak with your account manager for more info on this. A more complex example could be:
<reevoo-reviewable-badge
trkref="TRKREF"
manufacturer="ford"
model="fiesta"
model-variant="SE"
model-year="2016"
body-type="hatchback"
used="0"
engine-type="diesel"
></reevoo-reviewable-badge>
Custom click action
Normally are click actions on badges defined by Reevoo administrators. As a default we open a lightbox when user clicks on the badge.
reevoo-click-action
attribute gives you posibility to control the behaviour and overwrite default setting.
Available options are open_lightbox
, open_window
, no_action
.
<reevoo-reviewable-badge
trkref="TRKREF"
sku="SKU"
reevoo-click-action="open_lightbox"
></reevoo-reviewable-badge>
Custom click callback
In cases when you need to implement your own logic around click action, we give you ability to define your custom javascript function. This function will be evaluated when user click on the badge, but after standard click action is executed. That means after lightbox is opened. You can use on-click
callback together with reevoo-click-action
setting.
on-click
attribute accept javascript function definition
<reevoo-reviewable-badge
trkref="TRKREF"
sku="SKU"
on-click="function(){ alert('badge clicked') }"
reevoo-click-action="no_action"
></reevoo-reviewable-badge>
Updated almost 3 years ago