Originally Posted by
swguy
My guess would be UK shipping hasn't been refactored the way the native shipping methods have. Look at includes/modules/shipping/freeshipper.php in 1.5.6c vs. 1.5.5f. See how in 1.5.6c in the constructor, it exits if sort_order is not set? Do the same thing.
thank you for the guidance. Still having an issue I guess I will need to look for support on the plugin support page.
This is what I had
PHP Code:
class ukpost { var $code, $title, $description, $enabled, $num_zones;
function ukpost() { $this->code = 'ukpost'; $this->title = MODULE_SHIPPING_UKPOST_TEXT_TITLE; $this->description = MODULE_SHIPPING_UKPOST_TEXT_DESCRIPTION; $this->sort_order = defined('MODULE_SHIPPING_UKPOST_SORT_ORDER') ? MODULE_SHIPPING_ZONES_SORT_ORDER : null; $this->icon = ''; $this->tax_class = MODULE_SHIPPING_UKPOST_TAX_CLASS; $this->tax_basis = MODULE_SHIPPING_UKPOST_TAX_BASIS;
if (zen_get_shipping_enabled($this->code)) { $this->enabled = ((MODULE_SHIPPING_UKPOST_STATUS == 'True') ? true : false); }
Replaced with this
PHP Code:
class ukpost { var $code, $title, $description, $enabled, $icon, $num_zones;
// class constructor
function __construct() { global $order, $db;
$this->code = 'ukpost'; $this->title = MODULE_SHIPPING_UKPOST_TEXT_TITLE; $this->description = MODULE_SHIPPING_UKPOST_TEXT_DESCRIPTION; $this->sort_order = defined('MODULE_SHIPPING_UKPOST_SORT_ORDER') ? MODULE_SHIPPING_ZONES_SORT_ORDER : null; if (null === $this->sort_order) return false; $this->icon = ''; $this->tax_class = MODULE_SHIPPING_UKPOST_TAX_CLASS; $this->tax_basis = MODULE_SHIPPING_UKPOST_TAX_BASIS;
if (zen_get_shipping_enabled($this->code)) { $this->enabled = ((MODULE_SHIPPING_UKPOST_STATUS == 'True') ? true : false); }
But still produced error in logs. In admin shipping when you activate the shipping module the icon stays red. Yet it all seems to work apart from the PHP errors in log.
Appreciate the help, thanks.
Bookmarks