PDA

View Full Version : Fatal error:



fatbloke
01-20-2007, 02:33 AM
Hi

I have just tried a test paypal purchase on my new install and got this error

Fatal error: Call to a member function on a non-object in /home/software/public_html/includes/modules/payment/paypal_ipn.php on line 521

Any ideas ?

Thanks

Roy

michael_s
01-20-2007, 09:05 AM
Read the sticky on paypal:
http://www.oscmax.com/forums/paypal/5240-other-paypal-issues.html

fatbloke
01-31-2007, 07:05 AM
Hi

I have tried that fix and I still get the error

Anything else i can try ?

Cheers

Roy

michael_s
01-31-2007, 07:56 AM
There are a couple of fixes in that thread... Read through the whole thing and make sure you follow all the steps.

Also, see the bugtracker, there are a couple of bugfixes there too.

fisk
01-31-2007, 06:09 PM
Edited because i'm a moron.... I did the fix at the end of the sticky post, and then loaded the BACKUP copy of the file back to the server instead of the modified file... doh! It works now.

fisk

Invizix
02-07-2007, 11:31 PM
The fix (last post) mentioned in the above sticky thread doesn't work for me at all, it just routes to a new error Line 550. Both the 521 and 550 lines seems to be code dealing with Encryption.

Am I required to have Enable Encrypted Web Payments? Also does my site need to use SSL in order to get the IPN to work??

If anyone can help, then please HELP!

Mushroom
02-08-2007, 04:04 PM
Looking at the module's description it does say it should process without encryption. Not a real good idea, but it should work.

Invizix
02-08-2007, 04:46 PM
@Mushroom

How did you get your's to work in your online store? I've read your posts for a couple week ago. I followed your directions step-by-step but it leaves my shop spitting out a Line 550 error, or what not.

I use osCMax v2 RC3-0-1. I have since reverted BACK to the original osCMax RC3-0-1 paypal-ipn.php file, and now all I keep seeing is an error message on BOTH sandbox and live:


We are sorry, we are experiencing temporary difficulties. Please try again later. If this error occurred while making a payment, avoid duplicate payments by checking your Account Overview before resending a payment.

Message 3005

I'm officially at my wits end with this... i'm TRYING my best to establish my retail businesses online, but with all this PayPal crap i'm starting to wonder if it's worth it.

@michael_s

When will be osCMax port start for Google Checkout? Also anyway you can mod it to support UPS, USPS, and FedEX?

Mushroom
02-08-2007, 04:58 PM
I'm left out because I do use SSL and bought a certificate. I went looking at paypal_IPN.php and the line numbers don't match up to the 1.4 file that was the first step in solving my problem. No other errors came up for me.. There are a number of ways, according to the file, that you can secure the communications.

At the point you are now I would be verifying I had the correct path to cURL and to OpenSSL. Those are questions your host can provide.

If you are going to do retail online sales I strongly suggest you do the same. I protect my customer's credit card info as if it was my own. That was one of the reasons I dumped my last cart. They emailed me the cc numbers and kept them in a database online for future viewing.
I don't need that kind of risk.
I have also had customers that emailed me to tell me they refused to place an order on my site because EVERY page wasn't (https:// ) secured. I know I run away when the any login or payment page isn't locked tight.

Invizix
02-08-2007, 05:05 PM
Yeah I understand that Mushroom, it's just i'm confused about this whole PayPal IPN crap i'm going through, and this constant Message 3005 error i'm receiving BOTH from sandbox and live.

It seems this has been an ongoing issue with PayPal since 2004 or 2005. Apparently the Message 3005 error is when an internal PayPal database function screws up or something like that.

Mushroom
02-08-2007, 05:13 PM
Or you are feeding a bad line. I went through the same thing. And I hadn't finished developing that solution then.
Go dl v1.4 ( just the one file) and start over. It's possible you missed something. Relax, it's best to work all this out before you go live. I spent most of December configuring and testing.

Invizix
02-08-2007, 06:14 PM
Does my PayPal account need to be setup as a Business Account? As of right now it's a Premier Account.

Mushroom
02-08-2007, 06:53 PM
Looking at PayPal, I don't see any real difference between yours and a Business Account.

Invizix
02-08-2007, 08:21 PM
Well the same Message 3005 issue occured even with the modded module... HOWEVER... I have resolved the issue... it's an error with PayPal, using the invoice variable in the IPN module...

I simply commented out (//) the line:
$parameters['invoice'] = substr($cart_PayPal_IPN_ID, strpos($cart_PayPal_IPN_ID, '-')+1);

in the paypal_ipn.php module, and this got rid of the Message 3005 problem. This line needs to be modified or something, to be more compatible and compliant with PayPal IPN.

However the Vouchers problem is still present (Bugtracker #157) and with the 'fix' applied causes the shopping cart to crash with the Fatal error: Call to a member function on a non-object message... so it's either a problem with the IPN module, or a problem with the Coupon / Gift Vouchers contribution.

Something in which I feel michael_s should look into for the next release, because it is the cause of the Line 521 error.

Other than that, the module works great.

Mushroom
02-08-2007, 09:13 PM
> Well the same Message 3005 issue occured even with this new module...
> HOWEVER... I have resolved this issue...
> it's an error with PayPal, using the invoice variable in the IPN module...
>
> I simply commented out (//) the line:
> $parameters['invoice'] = substr($cart_PayPal_IPN_ID, strpos($cart_PayPal_IPN_ID, '-
> ')+1);
That says you are sending a string that PayPal can't/Won't handle. I'd drop back and see what is generated to fill that string.
I use aggregate are you using per item in the Admin config for paypal?

>
> in the paypal_ipn.php module, and this got rid of the Message 3005 problem. :)
>
> However the Vouchers problem is still present (Bugtracker #157) and with the 'fix' applied causes the shopping cart to crash with the Fatal error: Call to a member function on a non-object message... so it's
> either a problem with the IPN module, or a problem with the Coupon / Gift
> Vouchers contribution.
>
What was the line number? It should have told you the module ( or it was in the address bar ) and the line number that where it crashed.

Have you any other payment modules installed?

I'll have to ponder if I did anything else for the voucher thing. I fixed my voucher problems before I dealt with the PayPal thing.
What happened to me, is PayPal suddenly stopped working. I didn't do a DARN thing. :) I went to IPN and fought through the same errors you posted.

> Other than that, the module works great.

So you are saying it sucks. :)
>
What version ARE you running?

Invizix
02-09-2007, 04:34 AM
I'm using aggregate for the PayPal IPN module. The PayPal IPN module is the only payment module I currently use. I'm using paypal_ipn.php v1.4-modded (same thing happens with the original paypal_ipn.php also) and osCMax v2 RC3-0-1.

Mushroom
02-10-2007, 08:36 AM
Did this get sorted out?

Invizix
02-10-2007, 06:01 PM
Yeah, but the one line required for me to comment it out for whatever reason, it still send an invoice, etc, so I have no idea what that line is actually used for.

Mushroom
02-10-2007, 07:49 PM
Looks to me like it sends your invoice number to PayPal.
I'm glad it's working.