rovshan Posted October 22, 2007 Share Posted October 22, 2007 function colissimo() { $this->code = 'colissimo'; $this->title = MODULE_SHIPPING_COLISSIMO_TEXT_TITLE; $this->description = MODULE_SHIPPING_COLISSIMO_TEXT_DESCRIPTION; $this->sort_order = MODULE_SHIPPING_COLISSIMO_SORT_ORDER; $this->icon = DIR_WS_ICONS . 'colissimo.gif'; $this->tax_class = MODULE_SHIPPING_COLISSIMO_TAX_CLASS; $this->enabled = MODULE_SHIPPING_COLISSIMO_STATUS; // disable the module if the order only weight > 28 global $PHP_SELF; if (basename($PHP_SELF) != FILENAME_MODULES) { global $cart; if ($this->enabled == true) { if ($cart->show_weight() > '28' && ($dest_country != 'FR') && ($dest_country != 'FX') ) { $this->enabled = false; } } } } problem is even when this shipping methode disabled in admin ( setting FALSE ) it is avalable on checkout_shipping.php for clients, so I think that something wrong in red part of this code... :angry: thnks in advance for help.... :) Link to comment Share on other sites More sharing options...
Guest Posted October 22, 2007 Share Posted October 22, 2007 osc it is a complicated "beast".It is showing because there some other palces where you will have to disable this.It took me a week to find where to disable.On my website I have 3 forms for check out.Nickanme,e-mail and password. Look at http://www.jesphoto.net if that what you want. Link to comment Share on other sites More sharing options...
rovshan Posted October 22, 2007 Author Share Posted October 22, 2007 osc it is a complicated "beast".It is showing because there some other palces where you will have to disable this.It took me a week to find where to disable.On my website I have 3 forms for check out.Nickanme,e-mail and password. Look at http://www.jesphoto.net if that what you want. I found...... here is right code: $this->enabled = ((MODULE_SHIPPING_COLISSIMOR2_STATUS == 'True') ? true : false); $dest_country = $order->delivery['country']['iso_code_2']; if ( ($this->enabled == true) && ($dest_country != 'FR') && ($dest_country != 'FX') ) { $this->enabled = false; } if ( ($this->enabled == true) && $cart->show_weight() > '4.5' ) { $this->enabled = false; } Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.