osCommerce and osCMax shopping cart software forums

Shopping Cart Software

osCommerce with teeth!

 
 

PayPal error "Call to a member function on a non-object

This is a discussion on PayPal error "Call to a member function on a non-object within the osCMax v2 Customization/Mods forums, part of the osCMax v2.0 Forums category; Testing payment process with PayPal sandbox. The PayPal payment completes OK, but when I click "Continue" at the last PayPal ...


Go Back   osCommerce and osCMax shopping cart software forums > osCMax v2.0 Forums > osCMax v2 Customization/Mods

Register FAQ Members List Calendar Mark Forums Read


Free community membership! Fast easy FREE membership
Reply

 

LinkBack Thread Tools
  #1  
Old 10-10-2006, 09:17 AM
New Member
 
Join Date: Sep 2006
Posts: 21
Thanks: 3
Thanked 13 Times in 5 Posts
Rep Power: 0
brendanl79 will become famous soon enough
Default PayPal error "Call to a member function on a non-object

Testing payment process with PayPal sandbox.

The PayPal payment completes OK, but when I click "Continue" at the last PayPal screen to return to my website, I get:

Fatal error: Call to a member function on a non-object in [redacted] ... /catalog/includes/modules/payment/paypal_ipn.php on line 521

The line in question reads:
$order_total_modules->apply_credit();

xargs grep from /catalog for " apply_credit" (with leading space):
./includes/classes/order_total.php: function apply_credit() {
./includes/modules/order_total/ot_coupon.php:function apply_credit() {
./includes/modules/order_total/ot_gv.php: function apply_credit() {

Is this perhaps as simple as a missing require statement?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
Advertisement
  #2  
Old 10-10-2006, 08:25 PM
New Member
 
Join Date: Oct 2006
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
stevew
Default

Having the same problem, any help would really be appreciated!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3  
Old 10-11-2006, 11:42 AM
Member
 
Join Date: Jan 2005
Posts: 49
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
Lobotaman
Default

Same exact problem here under the same scenario.

This makes three of us in one day.

Anybody had any luck with this yet?

Please help, this is the last piece of the puzzle.

Thanks,

Lobo
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4  
Old 10-15-2006, 02:34 PM
New Member
 
Join Date: Oct 2006
Posts: 6
Thanks: 0
Thanked 1 Time in 1 Post
Rep Power: 0
jackxwu
Default

make it 4. i have RC3 just installed. testing through real paypal accounts, not sandbox. so it is not paypal's problem.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5  
Old 10-15-2006, 02:57 PM
New Member
 
Join Date: Nov 2004
Posts: 10
Thanks: 1
Thanked 3 Times in 1 Post
Rep Power: 0
Asgoroth is on a distinguished road
Default Been fighting this for a week now.

I have been searching the forums on ths matter without luck. I have been looking through the code, but so far am not able to figure out what might be wrong. It is most likely my limited PHP skills are just being stretched beyond their limits. I have not added any mods or made any changes to the base code yet. I am running RC3
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #6  
Old 10-15-2006, 03:53 PM
New Member
 
Join Date: Oct 2006
Posts: 6
Thanks: 0
Thanked 1 Time in 1 Post
Rep Power: 0
jackxwu
Default tried RC2

i replaced the paypal_ipn.php with its rc2 version and received the following error:

Fatal error: Cannot redeclare class order_total in /homepages/28/d173936077/htdocs/shop/includes/classes/order_total.php on line 13

same error when i replaced the paypal_ipn.php with the oscommerce one which does not have Bugfix 157, which seem to be the problem.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #7  
Old 10-15-2006, 05:20 PM
New Member
 
Join Date: Oct 2006
Posts: 6
Thanks: 0
Thanked 1 Time in 1 Post
Rep Power: 0
jackxwu
Default RE: tried RC2

OK. here is what i did to fix this:

1. replace paypal_ipn.php with the file in
osCommerce PayPal IPN Module v1.3 For 2.2MS2
http://www.oscommerce.com/community/.../search,paypal
this removes bugfix 157 but keeps bug fix 47, which i think is a good thing.

2. you will hit the Cannot redeclare class order_total problem, which was there when rc2 was released. the fix is in this thread:
http://oscdox.com/PNphpBB2-viewtopic...ht-paypal.html

i have verified after this fix, my paypal and order details works fine. some people had problems with other payment methods after applying #2. for those i have no idea what to do.

jack.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
The Following User Says Thank You to jackxwu For This Useful Post:
brendanl79 (02-10-2007)
  #8  
Old 10-15-2006, 06:54 PM
New Member
 
Join Date: Nov 2004
Posts: 10
Thanks: 1
Thanked 3 Times in 1 Post
Rep Power: 0
Asgoroth is on a distinguished road
Default

Implimented and testing so far looks to be good.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #9  
Old 10-22-2006, 04:27 PM
Active Member
 
Join Date: May 2004
Location: somewhere above colchester uk
Posts: 147
Thanks: 0
Thanked 1 Time in 1 Post
Rep Power: 0
battleaxe
Default

Quote:
K. here is what i did to fix this:

1. replace paypal_ipn.php with the file in
osCommerce PayPal IPN Module v1.3 For 2.2MS2
http://www.oscommerce.com/community/con ... rch,paypal
this removes bugfix 157 but keeps bug fix 47, which i think is a good thing.

2. you will hit the Cannot redeclare class order_total problem, which was there when rc2 was released. the fix is in this thread:
http://oscdox.com/PNphpBB2-viewtopic-t- ... aypal.html

i have verified after this fix, my paypal and order details works fine. some people had problems with other payment methods after applying #2. for those i have no idea what to do.

jack.
Hi Jack
Installed the new files, but end up with the line 13 thing. There are several paypal_ipn.php files, do you mean install them all? Or is it just one overwrite? I have a store going live using Paypal in a couple of weeks and I have been looking for a solution for days.
When I follow the instructions to kill the "line 13" problem it throws up all othre kinds of difficulties. I have reported as a bug, but as Paypal is the only card processor I use it is a make or break problem for me at the moment.
Cheers
Kim
__________________
Google says be nice!
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #10  
Old 10-25-2006, 11:51 AM
New Member
 
Join Date: Sep 2006
Posts: 21
Thanks: 3
Thanked 13 Times in 5 Posts
Rep Power: 0
brendanl79 will become famous soon enough
Default

When I decided to establish my OSC store I was under the impression that there are live stores up and running with it. But here we have PayPal not working out of the box. Was I wrong?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
Advertisement
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
PayPal error "Call to a member function on a non-object brendanl79 osCMax v2 Features Discussion 1 10-12-2006 10:12 PM
Fatal error: Call to undefined function: tep_href_link() spiros71 osCommerce 2.2 Installation Help 1 09-26-2005 02:23 PM
Fatal Error:Call to undefined function:gzinflate() michaelphodges osCMax v2 Installation issues 1 06-16-2005 08:26 AM
Fatal error: Call to undefined function: array_map() Anonymous osCMax v1.7 Discussion 3 01-21-2004 12:38 PM
Fatal error: Call to undefined function: array_map() Anonymous osCMax v1.7 Discussion 1 08-22-2003 10:30 PM


All times are GMT -8. The time now is 03:00 PM.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO
http://www.oscmax.com/forums/
Copyright 2008 osCMax