Bit of code that nobody every bothered to fix before as the error only ever appears in console. Open: /javascript/common.js Find: Replace with:
Category: Javascript
MacOS 404 error when Ajax fastcart fails to handle redirect correctly.
Behaviour:Some browsers (most notably on MacOS) seem to drop Ajax calls that should be appearing in the fastcart pop-over and pass them to a new tab or the parent window resulting in the end-user getting a 404. This seems to happen when the cart has returned an error such as “insufficient stock for that product”…
Set Name/Email/OrderID in Crisp Automatically
This code will check if email address / order ID exists, then push user name/email/segment to Crisp automatically. Add following code to the footer of both Desktop and Mobile templates.
Use Javascript to block page access when Web Browser Push Notification not granted
Usage You want to allow only web push notification subscribers to access a particular page. If push notification is not granted, the visitor will be alerted and redirected to another page. Implementation Create push-test.js with following code Add the following code to the page you want to protect