Skip to content

Shopping Cart Mods

Category: Javascript

unreachable code after return statement – common.js

Posted on June 9, 2019June 9, 2019 by Martin

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:

CategoriesBug Fix, Interspire Shopping Cart, Javascript

MacOS 404 error when Ajax fastcart fails to handle redirect correctly.

Posted on March 21, 2019March 21, 2019 by Martin

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”…

CategoriesBug Fix, Interspire Shopping Cart, Javascript

Set Name/Email/OrderID in Crisp Automatically

Posted on March 9, 2019March 15, 2019 by Eric

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.

CategoriesCrisp, Interspire Shopping Cart, Javascript

Use Javascript to block page access when Web Browser Push Notification not granted

Posted on March 3, 2019 by Eric

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

CategoriesHow To, Javascript, Security

Categories

  • Admin (3)
  • Analytics (1)
  • Apache (7)
  • Automation (1)
  • Bug Fix (33)
  • Crisp (6)
  • Database (3)
  • Email (2)
  • How To (6)
  • Integration (3)
  • Interspire Shopping Cart (65)
  • Javascript (4)
  • Mobile (9)
  • Open Graph (4)
  • Optimization (46)
  • PHP (8)
  • Push Notification (2)
  • Security (9)
  • SEO (13)
  • Server (5)
  • SSH (2)
  • Stripe (4)
  • Upgrade (2)

Contact

  • admin@moddiy.info