I am following the instructions from Google for how to install a Google Review pop-up after a customer has completed their order. They've given me this script but I'm not sure which file to paste it in. Should it be onlineshop/catalog/language/english/checkout/success.php?
<script src="https://apis.google.com/js/platform.js? ... enderOptIn"; async defer></script>
<script>
window.renderOptIn = function() {
window.gapi.load('surveyoptin', function() { window.gapi.surveyoptin.render( { "merchant_id": 108198874, "order_id": "ORDER_ID", "email": "CUSTOMER_EMAIL", "delivery_country": "COUNTRY_CODE", "estimated_delivery_date": "YYYY-MM-DD" }); });
}
</script>
Followed should help you in details on how to apply the order variables from the controllers and then to output the results to your JS code in your success.twig file: viewtopic.php?f=24&t=191768
Dedication and passion goes to those who are able to push and merge a project.
Regards,
Straightlight
Programmer / Opencart Tester
Who is online
Users browsing this forum: No registered users and 7 guests