AddShoppers Help Desk

Support Center

How to Add Rich Data to Product Shares

Last Updated: Dec 31, 2013 03:50PM EST

There are 3 ways to attach rich data (image, price, etc) to shares: 

1. By using tagging your pages with Product Schema code. 

2. By adding Javascript variables to the Social Analytics footer code.

3. Facebook OG Tags.

Method #1 - Product Schema (recommended)

Mark up your pages with tags. 

For a quick implementation (actually marking up your pages is recommended), add this code to your product view template, replacing with the correct variables. All values are optional. 

<div itemscope itemtype="" style="display: none;">
    <span itemprop="name">PRODUCT NAME VARIABLE HERE</span>
    <span itemprop="description">PRODUCT DESCRIPTION VARIABLE HERE</span>
    <img itemprop="image" src="PRODUCT IMAGE VARIABLE HERE"/>
    <div itemprop="offers" itemscope itemtype="">
        <span itemprop="price">PRODUCT PRICE HERE</span>
        ‚Äč<link itemprop="availability" href="" />
    <div itemprop="aggregateRating"
    itemscope itemtype="">
        <span itemprop="ratingValue">PRODUCT RATING HERE</span>
        <span itemprop="reviewCount">NUMBER OF RATINGS</span>
        <span itemprop="worstRating">LOWEST POSSIBLE RATING</span>
        <span itemprop="bestRating">HIGHEST POSSIBLE RATING</span>

NOTE: We might already have the correct Product Schema codes for your eCommerce platform: AddShoppers Product Schema Codes

Here's a live example of a page with correct Product Schema markup. Check the source to see how it's done!

Method #2 - Javascript Variables

The AddShoppersTracking variable in your Social Analytics code can accommodate the following attributes:

AddShoppersTracking = { 
          url: '', 
          name: '', 
          image: '', 
          description: '', 
          stock: '', 
          price: '', 
          rating: '' 

Just add the correct variables next to the corresponding attribute (again, all are optional).

Here's a live example of a page using AddShoppersTracking to tag rich product data. Check the source to see the AddShoppersTracking object.

Please note that once the AddShoppers widget loads, changes to AddShoppersTracking will have no effect UNLESS you reload the widget by calling AddShoppersWidget.onload();

Method #3 - Facebook OG Tags

If none of the methods above are detected, we will also pick up Facebook OG tags, if available. We'll pick up the og:image, og:description, and og:title tags. You cannot specify product price, rating, and stock status with this method, so the other 2 methods are recommended.

Contact Us

  • Please use the floating chat bubble in the bottom right hand side of your screen to initiate a request.
seconds ago
a minute ago
minutes ago
an hour ago
hours ago
a day ago
days ago
Invalid characters found