Zen Cart BOGO module update

A bug was found in BOGO Discount for Zen Cart, which will affect configurations using Discount Basis other than “No Restriction.”

The issue was that BOGO would not continue to other items after granting the first discount in these situations.  So if you have “Buy 1 Get 1 Free” with Discount Basis “Same Item”, and you had 2 of item 12 at $10.00 each, and 2 of item 15 at $5 each, it would only discount the item 12 (whereas the correct discount would be the item 12 + the item 15).

Thanks to the good folks at AliensAndStrangersMusic for helping me find this issue.

Checkbox Cross Sell for Zen Cart Better Together

Zen Cart Checkbox Cross Sell allows your customers to add additional items (cross sells) to their cart when buying another item. It uses the configuration from Better Together to make suggestions from a list of items without attributes. It’s a great way to increase the value of each customer order.

Checkbox Cross Sell is the latest addition to the Better Together World for Zen Cart.

The Zen Cart Matrix o’ Discounts

Whenever a customer asks me about Zen Cart Discounting Modules, I point them to the Zen Cart Matrix o’ Discounts on my site.  People really like the example style format that the discounts are listed in, because they can find the discounting plan they want to use and determine the software that supports it.

“Buy some quantity, get specific item free” in Zen Cart Big Chooser

Most people, when doing an item-count based discount, just want the least expensive item to be discounted. This kind of discount – “Buy 3, get a 4th item free” can be done with Zen Cart Big Chooser. But sometimes people want to specify a particular item: “Buy 3, get product 768 free.” This will work as long as product 768 is less expensive than the other 3 items in the cart – because Big Chooser selects items to meet the condition from most expensive to least expensive, and selects items to be discounted from least expensive to most expensive.

One customer had a high-priced item that was old stock that they wanted to clear out, so Big Chooser changes were required. So to allow I modified the behavior of set_negative_constraint in Big Chooser to make it work the way Big Spender does – simply eliminating the item from the decision about whether or not the constraint is met, but keeping it as a possibly discountable item. So you can say

   $this->add_condition("Buy any 3 items, get item 768 free", false); 
      $this->set_constraint(MINPRICE, 0.01, 3);
      $this->set_negative_constraint(PROD, 768);
      $this->set_discount(PROD, 768, 1, "%", 100);

and product 768 will be discounted even if it’s the most expensive item in the cart.

The change to allow discounting the negative constraint was added to Big Chooser for Zen Cart 1.2.16, released last week.

Updates to Zen Cart Better Together Checkout Candy

The Checkout Candy addition to Zen Cart Better Together has had a help update to show how to tweak the Checkout Candy display on the Shopping Cart page. You can

  • Reduce the total number of items shown
  • Reduce the number of items shown for each product (if a product is linked to many possible discounts).
  • Randomize the order of results

See Checkout Candy Installation Tweaks.

Creating attribute based discounts in Zen Cart – bugfix

An issue was discovered in Zen Cart Big Chooser which affects people trying to create discounts based on products with specific attribute settings.  As an example,

 $this->add_condition("Buy 22 boxed edition, get download edition free", true);
     $this->set_constraint(PROD, 22, 1);
     $this->set_constraint_attrfilter(5, 13);
     $this->set_discount(PROD, 22, 1, "%", 100);
     $this->set_discount_attrfilter(5, 10);

This discount allows to to offer product 22 (with attribute 5 set to value 10) free when product 22 (with attribute 5 set to 13) is purchased.  This style of discounting works correctly in Big Chooser 1.2.15.

Handling partial quantities in Zen Cart Better Together, Combination Discounts and Big Chooser

Some shops, such as those selling cloth or weighed goods, find it advantageous to set Admin->Configuration->Stock->Product Quantity Decimals to 2 instead of 0, and set the per product minimums to a fractional value. But my discount modules assume any quantity in the cart is at least 1 (i.e. it suffices to meet the condition in a linkage). To overcome this, simply round the quantity of each item in the cart to an integer value, and skip over the items which round to 0.  Detailed instructions for  Better Together, Combination Discounts and Big Chooser are provided in this article on Zen Cart Advanced Discount Configuration.  (See example 5.)