Disable automatic sorting of shipping in 4.2.3 onwards v1.0
Location: Shortcut to Homepage / Free CubeCart 4 Mods / Disable automatic sorting of shipping in 4.2.3 onwards v1.0
Disable automatic sorting of shipping in 4.2.3 onwards v1.0

This is for CubeCart 4. 

In CubeCart 4.2.3 changes were added so that shipping options are always sorted in order of increasing price.

This is not ideal in some circumstances, such as when there are free options such as 'Free Pick Up' which would then be listed first and may be selected by accident by customers.  It is also not ideal when you are using my 'All In One' Shipping module since this shipping module already has options for sorting the shipping options (Same order as created, Cheapest first, Most expensive first).

If you are new to CubeCart mods please refer to my Hints & Tips document.


Instructions to disable the automatic sorting of shipping options in CubeCart 4.2.3 and newer versions.

DOWNLOAD and OPEN includes/content/cart.inc.php

Make a BACKUP copy of the file.

FIND this line:

			usort($Shipping, "cmp");

REPLACE with this block:

 			/* start mod: Disable the automatic sorting of shipping options - by Estelle */
			/* usort($Shipping, "cmp"); */
 			/* end mod: Disable the automatic sorting of shipping options - by Estelle */

SAVE and UPLOAD the file.


  Add to Registry Add to Wish List Price: AU$0.00


  Related Products


Copyright © 2005 - 2011 Estelle WinterfloodVPS Hosting by Linode