Forums / Built-in Shipping and Payment Modules / Cloned shipping module problem

Cloned shipping module problem

Locked

Started by psr_racing on 29 Jan 2008, 1:57 PM · Views: 3,980

Results 1 to 20 of 23
This thread is locked. New replies are disabled.
29 Jan 2008, 1:57 PM
#1
psr_racing avatar

psr_racing

New Zenner

Join Date:
Feb 2007
Posts:
90
Plugin Contributions:
0

Cloned shipping module problem

I just attemted to clone a shipping module (storepickup) to create an identical module (COD). I went through and changed 'storepickup' to 'cod' and 'STOREPICKUP' to 'COD' in both the relevant files but now i get this error under the Admin/ shipping modules
Fatal error: Cannot redeclare class storepickup in /home/pow10934/public_html/includes/modules/shipping/storepickup.php on line 13

I cant work out where I went wrong, especially as line 13 doesn't seem relevant to the operation of the file?
Also the 'storepickup' module now doesnt show under 'shipping modules' and the 'COD' module is showing as MODULE_SHIPPING_COD_TEXT_TITLE instead of just 'COD'
Storepickup still shows up as an option to shoppers though?

29 Jan 2008, 5:05 PM
#2
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: Cloned shipping module problem

When you say you changed the 'storepickup' to 'cod', there should have been 3 of these to change. There is a class xxxxx extends base, a function xxxx { and a this->code = 'xxxx' to change.

Did you do all three?

You also need to ensure the new file is called cod.php, as the class name is pulled from the file name.

Absolute

Back, after a 4 year absence! Did you miss me?
Absolute Web Solutions Ltd
Interested in our work? Take a look at one of our sites - The Tech Store

29 Jan 2008, 11:20 PM
#3
psr_racing avatar

psr_racing

New Zenner

Join Date:
Feb 2007
Posts:
90
Plugin Contributions:
0

Re: Cloned shipping module problem

I'm sorry you've lost me. I cloned admin/includes/modules/shipping/storepickup.php and admin/includes/languages/english/modules/shipping/storepickup.php is there another one?

30 Jan 2008, 8:02 AM
#4
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: Cloned shipping module problem

Those are the correct files.but they are in the store side, not the admin side of the cart.

Within the actual file, there are 3 places where you need to change the work "storepickup" to "cod". Those are listed above.

Absolute

Back, after a 4 year absence! Did you miss me?
Absolute Web Solutions Ltd
Interested in our work? Take a look at one of our sites - The Tech Store

30 Jan 2008, 10:35 PM
#5
psr_racing avatar

psr_racing

New Zenner

Join Date:
Feb 2007
Posts:
90
Plugin Contributions:
0

Re: Cloned shipping module problem

There was a lot more than 3, I went through and changed every instance of 'storepickup' to 'cod' in both files.

30 Jan 2008, 10:43 PM
#6
shrimp_gumbo_mmmhhh avatar

shrimp_gumbo_mmmhhh

Totally Zenned

Join Date:
Jun 2007
Location:
Texas, USA
Posts:
1,436
Plugin Contributions:
0

Re: Cloned shipping module problem

psr racing:

There was a lot more than 3, I went through and changed every instance of 'storepickup' to 'cod' in both files.

Fatal error: Cannot redeclare class storepickup

Hello,

Can you post your "COD" module code? .... If so I think we probably could spot the problem pretty quickly. From the error message I would say you didn't rename the class on the new module...

Shrimp-Gumbo

30 Jan 2008, 10:53 PM
#7
shrimp_gumbo_mmmhhh avatar

shrimp_gumbo_mmmhhh

Totally Zenned

Join Date:
Jun 2007
Location:
Texas, USA
Posts:
1,436
Plugin Contributions:
0

Re: Cloned shipping module problem

Did you create a language file for the new module?

30 Jan 2008, 10:58 PM
#8
psr_racing avatar

psr_racing

New Zenner

Join Date:
Feb 2007
Posts:
90
Plugin Contributions:
0

Re: Cloned shipping module problem

OK I see now, the files are at public_HTML/includes/modules/shipping/storepickup and public_HTML/includes/languages/english/modules/shipping/storpickup.php

they were the ones I changed

30 Jan 2008, 11:00 PM
#9
psr_racing avatar

psr_racing

New Zenner

Join Date:
Feb 2007
Posts:
90
Plugin Contributions:
0

Re: Cloned shipping module problem

<?php // // +----------------------------------------------------------------------+ // |zen-cart Open Source E-commerce | // +----------------------------------------------------------------------+ // | Copyright (c) 2003 The zen-cart developers | // | | // | <http://www.zen-cart.com/index.php> | // | | // | Portions Copyright (c) 2003 osCommerce | // +----------------------------------------------------------------------+ // | This source file is subject to version 2.0 of the GPL license, | // | that is bundled with this package in the file LICENSE, and is | // | available through the world-wide-web at the following url: | // | <http://www.zen-cart.com/license/2_0.txt>. | // | If you did not receive a copy of the zen-cart license and are unable | // | to obtain it through the world-wide-web, please send a note to | // | [[email protected]](mailto:"[email protected]") so we can mail you a copy immediately. | // +----------------------------------------------------------------------+ // $Id: cod.php 1969 2005-09-13 06:57:21Z drbyte $ // define('MODULE_SHIPPING_COD_TEXT_TITLE', 'cod'); define('MODULE_SHIPPING_COD_TEXT_DESCRIPTION', 'Customer In Store Pick-up'); define('MODULE_SHIPPING_COD_TEXT_WAY', 'Must be selected for COD orders'); ?>
30 Jan 2008, 11:05 PM
#10
shrimp_gumbo_mmmhhh avatar

shrimp_gumbo_mmmhhh

Totally Zenned

Join Date:
Jun 2007
Location:
Texas, USA
Posts:
1,436
Plugin Contributions:
0

Re: Cloned shipping module problem

psr racing:

<?php // // +----------------------------------------------------------------------+ // |zen-cart Open Source E-commerce | // +----------------------------------------------------------------------+ // | Copyright (c) 2003 The zen-cart developers | // | | // | <http://www.zen-cart.com/index.php> | // | | // | Portions Copyright (c) 2003 osCommerce | // +----------------------------------------------------------------------+ // | This source file is subject to version 2.0 of the GPL license, | // | that is bundled with this package in the file LICENSE, and is | // | available through the world-wide-web at the following url: | // | <http://www.zen-cart.com/license/2_0.txt>. | // | If you did not receive a copy of the zen-cart license and are unable | // | to obtain it through the world-wide-web, please send a note to | // | license AT zen-cart DOT com so we can mail you a copy immediately. | // +----------------------------------------------------------------------+ // $Id: cod.php 1969 2005-09-13 06:57:21Z drbyte $ // define('MODULE_SHIPPING_COD_TEXT_TITLE', 'cod'); define('MODULE_SHIPPING_COD_TEXT_DESCRIPTION', 'Customer In Store Pick-up'); define('MODULE_SHIPPING_COD_TEXT_WAY', 'Must be selected for COD orders'); ?>

Just confirming that this file is called public_HTML/includes/languages/english/modules/shipping/cod.php?

Also, need to see your module file too.... public_HTML/includes/modules/shipping/cod.php

30 Jan 2008, 11:10 PM
#11
psr_racing avatar

psr_racing

New Zenner

Join Date:
Feb 2007
Posts:
90
Plugin Contributions:
0

Re: Cloned shipping module problem

Yes that was the public_HTML/includes/languages/english/modules/shipping/cod.php

This is the other one

<?php /** * @package shippingMethod * @copyright Copyright 2003-2006 Zen Cart Development Team * @copyright Portions Copyright 2003 osCommerce * @license <http://www.zen-cart.com/license/2_0.txt> GNU Public License V2.0 * @version $Id: cod.php 4821 2006-10-23 10:54:15Z drbyte $ */ /** * cod / Will-Call shipping method * */ class storepickup extends base { /** * $code determines the internal 'code' name used to designate "this" payment module * * @var string */ var $code; /** * $title is the displayed name for this payment method * * @var string */ var $title; /** * $description is a soft name for this payment method * * @var string */ var $description; /** * module's icon * * @var string */ var $icon; /** * $enabled determines whether this module shows or not... during checkout. * * @var boolean */ var $enabled; /** * constructor * * @return cod */ function cod() { global $order, $db; $this->code = 'cod'; $this->title = MODULE_SHIPPING_COD_TEXT_TITLE; $this->description = MODULE_SHIPPING_COD_TEXT_DESCRIPTION; $this->sort_order = MODULE_SHIPPING_COD_SORT_ORDER; $this->icon = ''; $this->tax_class = MODULE_SHIPPING_COD_TAX_CLASS; $this->tax_basis = MODULE_SHIPPING_COD_TAX_BASIS; $this->enabled = ((MODULE_SHIPPING_COD_STATUS == 'True') ? true : false); if ( ($this->enabled == true) && ((int)MODULE_SHIPPING_COD_ZONE > 0) ) { $check_flag = false; $check = $db->Execute("select zone_id from " . TABLE_ZONES_TO_GEO_ZONES . " where geo_zone_id = '" . MODULE_SHIPPING_COD_ZONE . "' and zone_country_id = '" . $order->delivery['country']['id'] . "' order by zone_id"); while (!$check->EOF) { if ($check->fields['zone_id'] < 1) { $check_flag = true; break; } elseif ($check->fields['zone_id'] == $order->delivery['zone_id']) { $check_flag = true; break; } $check->MoveNext(); } if ($check_flag == false) { $this->enabled = false; } } } /** * Obtain quote from shipping system/calculations * * @param string $method * @return array */ function quote($method = '') { global $order; $this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_COD_TEXT_TITLE, 'methods' => array(array('id' => $this->code, 'title' => MODULE_SHIPPING_COD_TEXT_WAY, 'cost' => MODULE_SHIPPING_COD_COST))); if ($this->tax_class > 0) { $this->quotes['tax'] = zen_get_tax_rate($this->tax_class, $order->delivery['country']['id'], $order->delivery['zone_id']); } if (zen_not_null($this->icon)) $this->quotes['icon'] = zen_image($this->icon, $this->title); return $this->quotes; } /** * Check to see whether module is installed * * @return boolean */ function check() { global $db; if (!isset($this->_check)) { $check_query = $db->Execute("select configuration_value from " . TABLE_CONFIGURATION . " where configuration_key = 'MODULE_SHIPPING_COD_STATUS'"); $this->_check = $check_query->RecordCount(); } return $this->_check; } /** * Install the shipping module and its configuration settings * */ function install() { global $db; $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Enable Store Pickup Shipping', 'MODULE_SHIPPING_COD_STATUS', 'True', 'Do you want to offer In Store rate shipping?', '6', '0', 'zen_cfg_select_option(array(\'True\', \'False\'), ', now())"); $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Shipping Cost', 'MODULE_SHIPPING_COD_COST', '0.00', 'The shipping cost for all orders using this shipping method.', '6', '0', now())"); $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Tax Class', 'MODULE_SHIPPING_COD_TAX_CLASS', '0', 'Use the following tax class on the shipping fee.', '6', '0', 'zen_get_tax_class_title', 'zen_cfg_pull_down_tax_classes(', now())"); $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Tax Basis', 'MODULE_SHIPPING_COD_TAX_BASIS', 'Shipping', 'On what basis is Shipping Tax calculated. Options are<br />Shipping - Based on customers Shipping Address<br />Billing Based on customers Billing address<br />Store - Based on Store address if Billing/Shipping Zone equals Store zone', '6', '0', 'zen_cfg_select_option(array(\'Shipping\', \'Billing\'), ', now())"); $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Shipping Zone', 'MODULE_SHIPPING_COD_ZONE', '0', 'If a zone is selected, only enable this shipping method for that zone.', '6', '0', 'zen_get_zone_class_title', 'zen_cfg_pull_down_zone_classes(', now())"); $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Sort Order', 'MODULE_SHIPPING_COD_SORT_ORDER', '0', 'Sort order of display.', '6', '0', now())"); } /** * Remove the module and all its settings * */ function remove() { global $db; $db->Execute("delete from " . TABLE_CONFIGURATION . " where configuration_key in ('" . implode("', '", $this->keys()) . "')"); } /** * Internal list of configuration keys used for configuration of the module * * @return array */ function keys() { return array('MODULE_SHIPPING_COD_STATUS', 'MODULE_SHIPPING_COD_COST', 'MODULE_SHIPPING_COD_TAX_CLASS', 'MODULE_SHIPPING_COD_TAX_BASIS', 'MODULE_SHIPPING_COD_ZONE', 'MODULE_SHIPPING_COD_SORT_ORDER'); } } ?>
30 Jan 2008, 11:12 PM
#12
shrimp_gumbo_mmmhhh avatar

shrimp_gumbo_mmmhhh

Totally Zenned

Join Date:
Jun 2007
Location:
Texas, USA
Posts:
1,436
Plugin Contributions:
0

Re: Cloned shipping module problem

psr racing:

Yes that was the public_HTML/includes/languages/english/modules/shipping/cod.php

This is the other one

<?php /** * @package shippingMethod * @copyright Copyright 2003-2006 Zen Cart Development Team * @copyright Portions Copyright 2003 osCommerce * @license <http://www.zen-cart.com/license/2_0.txt> GNU Public License V2.0 * @version $Id: cod.php 4821 2006-10-23 10:54:15Z drbyte $ */ /** * cod / Will-Call shipping method * */ class storepickup extends base { /** * $code determines the internal 'code' name used to designate "this" payment module * * @var string */ var $code; /** * $title is the displayed name for this payment method * * @var string */ var $title; /** * $description is a soft name for this payment method * * @var string */ var $description; /** * module's icon * * @var string */ var $icon; /** * $enabled determines whether this module shows or not... during checkout. * * @var boolean */ var $enabled; /** * constructor * * @return cod */ function cod() { global $order, $db; $this->code = 'cod'; $this->title = MODULE_SHIPPING_COD_TEXT_TITLE; $this->description = MODULE_SHIPPING_COD_TEXT_DESCRIPTION; $this->sort_order = MODULE_SHIPPING_COD_SORT_ORDER; $this->icon = ''; $this->tax_class = MODULE_SHIPPING_COD_TAX_CLASS; $this->tax_basis = MODULE_SHIPPING_COD_TAX_BASIS; $this->enabled = ((MODULE_SHIPPING_COD_STATUS == 'True') ? true : false); if ( ($this->enabled == true) && ((int)MODULE_SHIPPING_COD_ZONE > 0) ) { $check_flag = false; $check = $db->Execute("select zone_id from " . TABLE_ZONES_TO_GEO_ZONES . " where geo_zone_id = '" . MODULE_SHIPPING_COD_ZONE . "' and zone_country_id = '" . $order->delivery['country']['id'] . "' order by zone_id"); while (!$check->EOF) { if ($check->fields['zone_id'] < 1) { $check_flag = true; break; } elseif ($check->fields['zone_id'] == $order->delivery['zone_id']) { $check_flag = true; break; } $check->MoveNext(); } if ($check_flag == false) { $this->enabled = false; } } } /** * Obtain quote from shipping system/calculations * * @param string $method * @return array */ function quote($method = '') { global $order; $this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_COD_TEXT_TITLE, 'methods' => array(array('id' => $this->code, 'title' => MODULE_SHIPPING_COD_TEXT_WAY, 'cost' => MODULE_SHIPPING_COD_COST))); if ($this->tax_class > 0) { $this->quotes['tax'] = zen_get_tax_rate($this->tax_class, $order->delivery['country']['id'], $order->delivery['zone_id']); } if (zen_not_null($this->icon)) $this->quotes['icon'] = zen_image($this->icon, $this->title); return $this->quotes; } /** * Check to see whether module is installed * * @return boolean */ function check() { global $db; if (!isset($this->_check)) { $check_query = $db->Execute("select configuration_value from " . TABLE_CONFIGURATION . " where configuration_key = 'MODULE_SHIPPING_COD_STATUS'"); $this->_check = $check_query->RecordCount(); } return $this->_check; } /** * Install the shipping module and its configuration settings * */ function install() { global $db; $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Enable Store Pickup Shipping', 'MODULE_SHIPPING_COD_STATUS', 'True', 'Do you want to offer In Store rate shipping?', '6', '0', 'zen_cfg_select_option(array(\'True\', \'False\'), ', now())"); $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Shipping Cost', 'MODULE_SHIPPING_COD_COST', '0.00', 'The shipping cost for all orders using this shipping method.', '6', '0', now())"); $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Tax Class', 'MODULE_SHIPPING_COD_TAX_CLASS', '0', 'Use the following tax class on the shipping fee.', '6', '0', 'zen_get_tax_class_title', 'zen_cfg_pull_down_tax_classes(', now())"); $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Tax Basis', 'MODULE_SHIPPING_COD_TAX_BASIS', 'Shipping', 'On what basis is Shipping Tax calculated. Options are<br />Shipping - Based on customers Shipping Address<br />Billing Based on customers Billing address<br />Store - Based on Store address if Billing/Shipping Zone equals Store zone', '6', '0', 'zen_cfg_select_option(array(\'Shipping\', \'Billing\'), ', now())"); $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) values ('Shipping Zone', 'MODULE_SHIPPING_COD_ZONE', '0', 'If a zone is selected, only enable this shipping method for that zone.', '6', '0', 'zen_get_zone_class_title', 'zen_cfg_pull_down_zone_classes(', now())"); $db->Execute("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Sort Order', 'MODULE_SHIPPING_COD_SORT_ORDER', '0', 'Sort order of display.', '6', '0', now())"); } /** * Remove the module and all its settings * */ function remove() { global $db; $db->Execute("delete from " . TABLE_CONFIGURATION . " where configuration_key in ('" . implode("', '", $this->keys()) . "')"); } /** * Internal list of configuration keys used for configuration of the module * * @return array */ function keys() { return array('MODULE_SHIPPING_COD_STATUS', 'MODULE_SHIPPING_COD_COST', 'MODULE_SHIPPING_COD_TAX_CLASS', 'MODULE_SHIPPING_COD_TAX_BASIS', 'MODULE_SHIPPING_COD_ZONE', 'MODULE_SHIPPING_COD_SORT_ORDER'); } } ?>

Just as I suspected!

class storepickup extends base {

change to:

class cod extends base {

should work then....

looks like you did a find and replace and missed that one :smile:

Shrimp-Gumbo

30 Jan 2008, 11:18 PM
#13
psr_racing avatar

psr_racing

New Zenner

Join Date:
Feb 2007
Posts:
90
Plugin Contributions:
0

Re: Cloned shipping module problem

Your a legend :cheers: how could I miss it right at the top there :lamo:

31 Jan 2008, 5:25 AM
#14
psr_racing avatar

psr_racing

New Zenner

Join Date:
Feb 2007
Posts:
90
Plugin Contributions:
0

Re: Cloned shipping module problem

What do I have to change to make my most expensive shipping option the default choice? (Per Unit)

31 Jan 2008, 11:12 AM
#15
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: Cloned shipping module problem

The default shipping method is calculated using a cheapest shipping class function. If you use the developers tool in the admin, oyu can see which file this function exists within. You would need to go through and either replace this with a new function, or butcher the cheapest function to return the most expensive method.

Personally, I would go with creating a new class function, so that it is obvious when you return the code in a year or so what is happening.

Absolute

Back, after a 4 year absence! Did you miss me?
Absolute Web Solutions Ltd
Interested in our work? Take a look at one of our sites - The Tech Store

31 Jan 2008, 8:33 PM
#16
shrimp_gumbo_mmmhhh avatar

shrimp_gumbo_mmmhhh

Totally Zenned

Join Date:
Jun 2007
Location:
Texas, USA
Posts:
1,436
Plugin Contributions:
0

Re: Cloned shipping module problem

Absolute:

The default shipping method is calculated using a cheapest shipping class function. If you use the developers tool in the admin, oyu can see which file this function exists within. You would need to go through and either replace this with a new function, or butcher the cheapest function to return the most expensive method.

Personally, I would go with creating a new class function, so that it is obvious when you return the code in a year or so what is happening.

Absolute

Absolute,

Does this also determine the way that it is ordered at checkout?

Thanks,

Shrimp

31 Jan 2008, 9:53 PM
#17
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: Cloned shipping module problem

The ordering in checkout is determined by the sort order in teh admin, if you have more than 1 module installed. If there is only 1 module installed, it is normally ordered depending on how it coded for each of the methods of transport. As you are cloning this aprticular method, then I would guess that you have more than 1 shipping module installed, in whioch case, you just need to change the module's sort order.

Absolute

Back, after a 4 year absence! Did you miss me?
Absolute Web Solutions Ltd
Interested in our work? Take a look at one of our sites - The Tech Store

28 Feb 2008, 9:45 AM
#18
psr_racing avatar

psr_racing

New Zenner

Join Date:
Feb 2007
Posts:
90
Plugin Contributions:
0

Re: Cloned shipping module problem

Well unfortunately it seems this error has come back to haunt me. I'm sure I got it working a month ago with the help of the people who posted above but now I have discovered it is returning the exact same error message when COD is selected. I don't know how long it has been doing this but I have tried recloning the shipping modules 3 times, even tried cloning different modules but cannot stop the error from coming up. I just cannot see what I have missed during the cloning process?

29 Feb 2008, 12:50 PM
#19
absolute avatar

absolute

Totally Zenned

Join Date:
May 2005
Location:
Bath, Somerset
Posts:
1,054
Plugin Contributions:
2

Re: Cloned shipping module problem

Firstly, what is the error - please paste errors so that we have a better idea of your problem.

Secondly, what is the filename of the new shipping module.

Thirdly, have you gone through and replaced all three references to 'storepickup' to 'cod'?

Absolute

Back, after a 4 year absence! Did you miss me?
Absolute Web Solutions Ltd
Interested in our work? Take a look at one of our sites - The Tech Store

29 Feb 2008, 12:57 PM
#20
psr_racing avatar

psr_racing

New Zenner

Join Date:
Feb 2007
Posts:
90
Plugin Contributions:
0

Re: Cloned shipping module problem

I've quoted the first post from this thread as this is what is happening again.
Only difference now is the mistake found earlier is now not the cause:frusty:

psr racing:

I just attemted to clone a shipping module (storepickup) to create an identical module (COD). I went through and changed 'storepickup' to 'cod' and 'STOREPICKUP' to 'COD' in both the relevant files but now i get this error under the Admin/ shipping modules
Fatal error: Cannot redeclare class storepickup in /home/pow10934/public_html/includes/modules/shipping/storepickup.php on line 13

I cant work out where I went wrong, especially as line 13 doesn't seem relevant to the operation of the file?
Also the 'storepickup' module now doesnt show under 'shipping modules' and the 'COD' module is showing as MODULE_SHIPPING_COD_TEXT_TITLE instead of just 'COD'
Storepickup still shows up as an option to shoppers though?