Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Recommended Posts

Posted

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

  • 2 weeks later...
Posted
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

  • 2 weeks later...
Posted
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é

Posted
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

  • 2 weeks later...
Posted

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.

 

screen.jpg

 

Rgds Andre

Posted
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.

 

screen.jpg

 

Rgds Andre

 

 

What is on you line 62 of the sofortueberweisungredirect.php file - you'll find it in includes/modules/payment?

Posted
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é

Posted
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

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...