andre07 Posted October 31, 2008 Posted October 31, 2008 Hi, i have a problem with an alternative payment method and the order editor. Can someone help? Thanks! I get this error: Fatal error: Call to undefined method: manualcart->generate_cart_id() in /home/u0026504243/public_html/shop/includes/modules/payment/sofortueberweisungredirect.php on line 62 Quote
wolfy Posted November 10, 2008 Posted November 10, 2008 Hi, i have a problem with an alternative payment method and the order editor. Can someone help? Thanks! I get this error: Fatal error: Call to undefined method: manualcart->generate_cart_id() in /home/u0026504243/public_html/shop/includes/modules/payment/sofortueberweisungredirect.php on line 62 Hi Not sure if this is going to work for you, but it worked for me. open catalog/includes/classes/payment.php and look for this code function selection() { $selection_array = array(); if (is_array($this->modules)) { reset($this->modules); while (list(, $value) = each($this->modules)) { $class = substr($value, 0, strrpos($value, '.')); if ($GLOBALS[$class]->enabled) { $selection = $GLOBALS[$class]->selection(); if (is_array($selection)) $selection_array[] = $selection; } } } return $selection_array; } and change it to function checkout_initialization_method() { $initialize_array = array(); if (is_array($this->modules)) { reset($this->modules); while (list(, $value) = each($this->modules)) { $class = substr($value, 0, strrpos($value, '.')); if ($GLOBALS[$class]->enabled && method_exists($GLOBALS[$class], 'checkout_initialization_method')) { $initialize_array[] = $GLOBALS[$class]->checkout_initialization_method(); } } } return $initialize_array; } hope this works for you :) Rgds wolfy Quote
andre07 Posted November 21, 2008 Author Posted November 21, 2008 Hi Not sure if this is going to work for you, but it worked for me. open catalog/includes/classes/payment.php and look for this code function selection() { $selection_array = array(); if (is_array($this->modules)) { reset($this->modules); while (list(, $value) = each($this->modules)) { $class = substr($value, 0, strrpos($value, '.')); if ($GLOBALS[$class]->enabled) { $selection = $GLOBALS[$class]->selection(); if (is_array($selection)) $selection_array[] = $selection; } } } return $selection_array; } and change it to function checkout_initialization_method() { $initialize_array = array(); if (is_array($this->modules)) { reset($this->modules); while (list(, $value) = each($this->modules)) { $class = substr($value, 0, strrpos($value, '.')); if ($GLOBALS[$class]->enabled && method_exists($GLOBALS[$class], 'checkout_initialization_method')) { $initialize_array[] = $GLOBALS[$class]->checkout_initialization_method(); } } } return $initialize_array; } hope this works for you :) Rgds wolfy Hi wolfy, unfortunately it's not working for me :-( I get the same error. Anyway thanks, André Quote
wolfy Posted November 21, 2008 Posted November 21, 2008 Hi wolfy, unfortunately it's not working for me :-( I get the same error. Anyway thanks, André Instead of replacing the code as I've mentioned above, add the code just below, so in other words you need to find function selection() { $selection_array = array(); if (is_array($this->modules)) { reset($this->modules); while (list(, $value) = each($this->modules)) { $class = substr($value, 0, strrpos($value, '.')); if ($GLOBALS[$class]->enabled) { $selection = $GLOBALS[$class]->selection(); if (is_array($selection)) $selection_array[] = $selection; } } } return $selection_array; } and just below that add function checkout_initialization_method() { $initialize_array = array(); if (is_array($this->modules)) { reset($this->modules); while (list(, $value) = each($this->modules)) { $class = substr($value, 0, strrpos($value, '.')); if ($GLOBALS[$class]->enabled && method_exists($GLOBALS[$class], 'checkout_initialization_method')) { $initialize_array[] = $GLOBALS[$class]->checkout_initialization_method(); } } } return $initialize_array; } What is the exact error message you are getting? Rgds Wolfy Quote
andre07 Posted December 1, 2008 Author Posted December 1, 2008 Hi Wolfy, the second code also not working for me :-( The exact error I get: Fatal error: Call to undefined method: manualcart->generate_cart_id() in /home/u0026504243/public_html/shop/includes/modules/payment/sofortueberweisungredirect.php on line 62 I get this error every time i click on "bearbeiten", when i try to edit a order. Rgds Andre Quote
wolfy Posted December 1, 2008 Posted December 1, 2008 Hi Wolfy, the second code also not working for me :-( The exact error I get: Fatal error: Call to undefined method: manualcart->generate_cart_id() in /home/u0026504243/public_html/shop/includes/modules/payment/sofortueberweisungredirect.php on line 62 I get this error every time i click on "bearbeiten", when i try to edit a order. Rgds Andre What is on you line 62 of the sofortueberweisungredirect.php file - you'll find it in includes/modules/payment? Quote
andre07 Posted December 2, 2008 Author Posted December 2, 2008 What is on you line 62 of the sofortueberweisungredirect.php file - you'll find it in includes/modules/payment? Line 62 is: if (empty($cart->cartID)) $cart->cartID = $cart->generate_cart_id(); If you need the complete file "sofortueberweisungredirect.php" i will send it. Thanks, André Quote
wolfy Posted December 2, 2008 Posted December 2, 2008 Line 62 is: if (empty($cart->cartID)) $cart->cartID = $cart->generate_cart_id(); If you need the complete file "sofortueberweisungredirect.php" i will send it. Thanks, André Hi andre, yes please send it - and also let me know if there are any other modules which you have installed which required changes to the catalog/checkout_payment.php, maby even to the classes/payment.php file. what version of oscom are you using? rgds wolfy Quote
wolfy Posted December 2, 2008 Posted December 2, 2008 Hi Andre I came across this, maybe you have too - its in German though, I tried to translate but Google translation did not work to well for me - but have a look at this link http://forums.oscommerce.de/index.php?showtopic=54778 rgds wolfy Quote
andre07 Posted December 2, 2008 Author Posted December 2, 2008 Many thanks! I found a solution in this thread. Regards Andre Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.