Please follow along with this seller review integration guide for even more details: https://help.shopperapproved.com/en/articles/2511237-shopper-approved-seller-review-integration-overview
You can then follow below to see where to place the code on Magento.
Step 1 - Add the seller survey code
Place the Thank you page code on your theme’s success.phtml template file via FTP access.
Common Locations:
app/design/frontend/{your_vendor_name}/{your_theme_name}/Magento_Checkout/templates/success.phtml
app/design/frontend/{your_vendor_name}/{your_theme_name}/Magento_InventoryInStorePickupFrontend/templates/success.phtml
Thank You Page Code (Seller Reviews code)
Thank You Page Code (Seller Reviews code)
<!-- Shopper Approved TY Page Code -->
<?php
$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$order = $objectManager->create('Magento\Sales\Model\Order')->loadByIncrementId($block->getOrderId());
if ($order->getCustomerIsGuest() && $order->getBillingAddress()) {
$customerName = $order->getBillingAddress()->getName();
//Use $order->getCustomerName() as a last resort
if (!trim($customerName)) {
$customerName = $order->getCustomerName();
}
} else {
$customerName = $order->getCustomerName();
}
$customerEmail = $order->getCustomerEmail();
$countryCode = $order->getShippingAddress()->getCountryId();
$customerCountry = $objectManager->create('\Magento\Directory\Model\Country')->load($countryCode)->getName();
$orderItems = $order->getAllVisibleItems();
$orderItemData = [];
?>
<script type="text/javascript">var siteID = xxxx; var siteToken = "xxxxx"; var sa_values = { "site":siteID, "token":siteToken, 'orderid':'<?= $block->getOrderId(); ?>', 'name':'<?= $customerName; ?>', 'email':'<?= $customerEmail; ?>', 'country':'<?= $customerCountry; ?>', 'state':'<?= $block->escapeHtml($order->getShippingAddress()->getRegionCode()); ?>' }; function saLoadScript(src) { var js = window.document.createElement("script"); js.src = src; js.type = "text/javascript"; document.getElementsByTagName("head")[0].appendChild(js); } var d = new Date(); saLoadScript("https://www.shopperapproved.com/thankyou/rate/" + siteID + ".js?d=" + d.getTime()); </script>
<!-- END Shopper Approved TY Page Code -->
Note: Please update the siteID and siteToken values to your own.
Once you collect seller reviews, you will want to place a dedicated seller reviews page on your site to display those reviews.
Step 2 - Add a seller reviews page
Location: Magento Dashboard > Content > Pages > Add New Page
Enter the ‘Page Title’ and ‘Edit with Page Builder’ to integrate the reviews page code.
2. Add the reviews page code snippet inside of the Page builder.
Output:
3. Add a Reviews page link in the footer.
Go to your Magento Dashboard > Content > Blocks > and select the available footer blocks where you want to add the reviews page link.
For this example, select the ‘Footer Cms Content’ block, edit it with Page Builder to add the html code for the reviews link.
Output:
Step 3 - Add a Seal
Go to your Magento Dashboard > Content > Blocks > and choose the available footer and header blocks where you want to display your seal.
Step 4- Add a Rotating Widget
Placement is typically above the footer on the home page.
Go to Magento Dashboard > Content > Pages > URL Key: home
2. Get the rotating widget code from the SA dashboard and add it through the HTML widget on the page builder.
Output:
If you are also collecting product reviews, continue here for how to add the product code to your Magento site.
https://app.intercom.com/a/apps/taxyni8e/knowledge-hub/article/10670381
If you are using Q&A, continue here for how to add the Q&A code to your Magento site.
If you have any questions, please contact [email protected].