Displaying a Separate Q&A Widget (Legacy)

Prev Next

Products


Reviews
Supported plans

Pro, Premium, Enterprise

eCommerce Platform

Shopify, Shopify Plus, Adobe Commerce (Magento), BigCommerce, WooCommerce, Volusion, Salesforce Commerce Cloud, Custom

This feature allows you to use the Q&A section separately from the Reviews Widget. By default, the two appear together, however you may want to have individual tabs or only the Q&A widget without the Reviews widget.

Is this article for me?
If you're using the new version of the Q&A Widget, see Customizing the Q&A Widget
Please note:
The look and feel of the Q&A dedicated widget is controlled by the Reviews Widget, even if you do not use the Reviews Widget.

Displaying the Q&A widget separately

  1. From your Yotpo Reviews main menu, go to On-Site Widgets.
  2. Click Q&A.
  3. Check the I’d like to have a separated Q&A widget checkbox.
  4. Click Generate Code.
  5. Copy the code snippet.
  6. Paste the code in the desired place in your store.
  7. Make sure to save the changes.
Please note:
Replace the values in the code snippet with the appropriate values for your website and products.The data-product-id attribute only supports alphanumeric (a...z, A...Z, 0...9) and "_" and "-" symbols

BigCommerce instructions

  1. Log into your BigCommerce admin.
  2. Click Script Manager.
  3. Click Create a Script.
  4. Choose the following options:
    • Location on Page - Footer
    • Select pages where script will be added - All pages (recommended)
    • Script Category - Essential (recommended)
    • Script Type - Script
  5. Paste the following code in the open script fields:
    JavaScript
    <script type="text/javascript">//<![CDATA[
                 var div = document.createElement("div");
                 div.setAttribute('class', 'yotpo yotpo-main-widget');
                 div.setAttribute('data-product-id',"{{product.id}}");
                 div.setAttribute('data-name',"{{product.title}}");
                 div.setAttribute('data-url', document.URL);
                 div.setAttribute('data-description',"");
                 div.setAttribute('data-image-url', "{{getImage product.main_image 'product'}}");
                 div.setAttribute('data-mode', "questions");
                 document.querySelectorAll('.productView')[0].appendChild(div)
                 //]]>
                 </script>
  6. Click Save.
    Your customers will now see a dedicated widget for questions and answers.

Volusion instructions

  1. Copy the code snippet and paste it in your product pages.
  2. Click Save Changes at the bottom of the screen.

Generic platform instructions

  1. Copy the code snippet and paste it in your product pages.
  2. Click Save Changes at the bottom of the screen.