You may have already heard that Mastercard is rolling out cards that start with a “2” instead of the traditional “5.” You’ll want to check your version of Zen Cart to be sure you can handle this. Versions 1.5.5b and above have built in logic for the native payment methods (such as Authorize.net); if you are running a lower version, you will need to merge in the changes from the latest copy of includes/classes/cc_validation.php. If you are using an extension to manage credit card payments, be sure to test with Mastercard 2223000048400011. Then you can have confidence that your cart properly processes “2” series Mastercard cards.
Better Together is a BOGO discounting module I created for Zen Cart. I have ported the logic to a few other carts (osCommerce, Prestashop, and OpenCart), and this post pertains to the OpenCart port.
The first release of the Better Together for OpenCart module was for OpenCart 1.5. Then I made a handful of tweaks for compatibility with version 2.0. Now I knew I had to upgrade for 2.3 compatibility, but since the version 2 changes were pretty easy, I honestly thought upgrading for version 18.104.22.168 of OpenCart would be trivial. I was wrong! There were a few tricky things, and I’ll share them here in case other software developers are working on upgrading their pre-2.3 extensions.
- The file paths are different. All file paths now include “extension” directories. So instead of
catalog/model/total/better_together.php, the file path becomes
- The inheritance hierarchy is different. So instead of declaring your model class as ModelYourClass, it’s ModelExtensionYourClass, which extends Model.
- This is what really tripped me up. Because the 2.3 base class overrides getters and setters, you have to be sure to declare all your class variables so that magic methods won’t be used to access them(*). If you came out of PHP4, this is a bit of an adjustment, but there you are. The positive thing is that it makes your code more self-documenting.
(*) If you don’t do this, you’ll get the “Indirect modification of overloaded property has no effect” fatal error.
Newsletter Discount for Zen Cart has a few new features:
- Dollar off per order setting
- Caching of Mailchimp subscriber status
So now, instead of
and instead of
If you’re getting this warning message in your ZenCart checkout using Paypal Payments Standard, fear not! There issue is just that Paypal is no longer using commas in the payment amount, and there’s a fix for it. The options are described in the Zen Cart forum thread PayPal deleting the comma from PayPal Standard in Jan 2017.
The mighty Googs have changed how their redirection works, so that search parameters are no longer passed to target pages. For this reason, my Zen Cart Welcome Google Searcher mod will no longer work.
So I decided to go with Jekyll, a Ruby based static site generator. I created a new website for my book group, using a gem that makes it easy to autogenerate Amazon affiliate URLs with the Product Advertising API.
I open sourced the project in case anyone else wants to build a book club website, or any other type of website that uses Amazon affiliate links.
My beloved book group website is getting the dreaded “not mobile-friendly” warning from Google. That’s because the site was built when “RWD” meant “rear-wheel drive,” not “responsive web design!” But challenge accepted – I will rework the site, and its 17 years of book choices – to be compatible with the modern web. And you, dear reader, will be lucky enough to follow my adventure!