PayPal Donation Extension

Not getting donors populated with phpBB 3.2 & ext 2.0.0-dev - PayPal Donation Extension

Not getting donors populated with phpBB 3.2 & ext 2.0.0-dev

by bloodbane » Mon Feb 06, 2017 5:35 pm

I am having issues getting ppde 2.0.0-dev working with phpBB 3.2.

The extension works when I use the paypal sandbox but not when I receive an actual transaction. Live transactions do not show in the transaction log at all. They do however generate "error" logs in store/ex/ppde/

On the Paypal site the IPN is pointed to https://MYSITEURL/app.php/ipn-listener

Any assistance would be greatly appreciated!

The log shows this...


[06-Feb-2017 17:09:33 0] Invalid response status:
[args]
business = XXXXXXXXXXXXXXXXXXXXXXXXXXXXXx;
confirmed = ;
exchange_rate = ;
first_name = David;
item_name = XXXXXXXXX;
item_number = ;
last_name = XXXX;
mc_currency = USD;
mc_gross = 5;
mc_fee = 0.45;
parent_txn_id = ;
payer_email = XXXXXXXXXXXx;
payer_id = XXXXXXXXXX;
payer_status = verified;
payment_date = 07%3A59%3A45+Feb+06%2C+2017+PST;
payment_status = Completed;
payment_type = instant;
receiver_id = XXXXXXXXXXXx;
receiver_email = XXXXXXXXXXXX;
residence_country = US;
settle_amount = 0;
settle_currency = ;
test_ipn = ;
txn_id = XXXXXXXXXXXx;
txn_type = web_accept;
bloodbane
Registered User
Posts: 7
Joined: Mon Feb 06, 2017 4:55 pm

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by Skouat » Tue Feb 07, 2017 12:03 am

The error is a generic message :?
I need to improve the error log to get more relevant information.

It may results of an invalid PayPal Merchant ID or Your board is not able to contact properly PayPal API.

Please check your PayPal Account ID.
What is the version of cURL and SSL ? (Go to the Overview module)
Skouat
Code Contributor
Posts: 1059
Joined: Mon Mar 10, 2008 5:30 pm
Location: France

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by bloodbane » Tue Feb 07, 2017 12:30 pm

Skouat wrote:The error is a generic message :?
I need to improve the error log to get more relevant information.

It may results of an invalid PayPal Merchant ID or Your board is not able to contact properly PayPal API.

Please check your PayPal Account ID.
What is the version of cURL and SSL ? (Go to the Overview module)
Thank you for the quick reply! The Paypal ID you mention is one of the email addresses on the account correct? If so, that is set correctly. I made a manual donation button to the same address and my users have been donating without issue. I see the hit from paypal's IPN service to my webserver, just not getting any results in the transaction log.

If you need any assistance in debugging this I may be able to assist. I am a developer myself, just not with PHP at this level. If there are some flags to set or quick edits to get more debug info I am happy to assist.

cURL version: 7.47.0
SSL version: OpenSSL/1.0.2g
bloodbane
Registered User
Posts: 7
Joined: Mon Feb 06, 2017 4:55 pm

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by Skouat » Tue Feb 07, 2017 7:05 pm

bloodbane wrote: I see the hit from paypal's IPN service to my webserver, just not getting any results in the transaction log.
When you go here ? You see the transaction ?
bloodbane wrote: If you need any assistance in debugging this I may be able to assist. I am a developer myself, just not with PHP at this level. If there are some flags to set or quick edits to get more debug info I am happy to assist.
Good to know. But I must improve the code to add more debug information.
Skouat
Code Contributor
Posts: 1059
Joined: Mon Mar 10, 2008 5:30 pm
Location: France

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by bloodbane » Tue Feb 07, 2017 7:07 pm

Yes, the transactions are listed in the PayPal IPN history.
bloodbane
Registered User
Posts: 7
Joined: Mon Feb 06, 2017 4:55 pm

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by Skouat » Tue Feb 07, 2017 8:13 pm

I have tested PPDE with a real transaction and I have no problems.

Code: Select all

[07-Feb-2017 21:05:57 3600] DEBUG VERIFIED:
--------------------------------------------------------------------------------
[02/07/2017 9:05 PM] - https://www.paypal.com/cgi-bin/webscr ( curl )
--------------------------------------------------------------------------------
HTTP/1.1 200 OK
Server: Apache
X-Frame-Options: SAMEORIGIN
Paypal-Debug-Id: 777dc92252551
Cache-Control: max-age=0, no-cache, no-store, must-revalidate
Pragma: no-cache
Content-Type: text/html; charset=UTF-8
DC: ccg11-origin-www-2.paypal.com
Date: Tue, 07 Feb 2017 20:05:57 GMT
Content-Length: 8
Connection: close

[***some text***]

VERIFIED

200
A new version is available on the Github repository.
Please, download it, disable the extension and replace all files, then enable the extension.
Skouat
Code Contributor
Posts: 1059
Joined: Mon Mar 10, 2008 5:30 pm
Location: France

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by bloodbane » Tue Feb 07, 2017 8:41 pm

Ok, so a couple of quick bits of feedback. After making the requested changes the log clearly tells me the 1st issue, the account name doesn't match. I had the email address in the extension, which seems to cause the issue. I changed it to use the merchant ID and now it is accepting transactions and they are making it into the database. So thank you for that additional logging! If the extension is going to require the ID instead of the email it would be good to update the label on that text box.

Now, when I go to view the transaction log I still see no records, however the transaction count is increased and the transaction is in the table. Also, when trying to view the user visible donor list the following error is on the page...


---------------------------------------------------------------------
Information

The “username” field does not exist.
bloodbane
Registered User
Posts: 7
Joined: Mon Feb 06, 2017 4:55 pm

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by Skouat » Tue Feb 07, 2017 9:20 pm

bloodbane wrote: Ok, so a couple of quick bits of feedback. After making the requested changes the log clearly tells me the 1st issue, the account name doesn't match. I had the email address in the extension, which seems to cause the issue. I changed it to use the merchant ID and now it is accepting transactions and they are making it into the database. So thank you for that additional logging! If the extension is going to require the ID instead of the email it would be good to update the label on that text box.
PPDE also works if you use the email address.
But it seems having some encoding issue with some board.
Maybe it could help : viewtopic.php?p=14539566#p14539566
bloodbane wrote: Now, when I go to view the transaction log I still see no records, however the transaction count is increased and the transaction is in the table. Also, when trying to view the user visible donor list the following error is on the page...


---------------------------------------------------------------------
Information

The “username” field does not exist.
Please, could you PM me a test account on your board?
Skouat
Code Contributor
Posts: 1059
Joined: Mon Mar 10, 2008 5:30 pm
Location: France

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by bloodbane » Wed Feb 08, 2017 12:57 pm

Ok, I changed the encoding to UTF-8.

I will PM you an account.

I did find that if I edit the table ppde_txn_log and update the user_id field that it will make the donors appear. Mine all appear to default to "0".
Is the extension requiring that the provided donor link be used? Almost all of my donations are repeated monthly so I think they just hit "resend" inside of Paypal.
bloodbane
Registered User
Posts: 7
Joined: Mon Feb 06, 2017 4:55 pm

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by Skouat » Wed Feb 08, 2017 2:44 pm

When you make a donation, You use the link donate locate on the Screenshot ?
Snap20170208150709.png
Snap20170208150709.png (4.37 KiB) Viewed 173 times
If yes, that why you facing to this issue.
bloodbane wrote: Is the extension requiring that the provided donor link be used? Almost all of my donations are repeated monthly so I think they just hit "resend" inside of Paypal.
Yes, you must use the donate link provided by the extension.
When you use this link, the extension generate a unique ID included in PayPal transaction.
Snap20170208150710.png
Snap20170208150710.png (3.29 KiB) Viewed 175 times
Whitout this simple information, we are not able to determine how link the PayPal donation to the phpBB member username.

I will try to add (with no warranty) to add a feature based on Custom Profil Field, that permit to the extension to retrieve the phpBB member user_id based on the PayPal Account ID.
Please, could you open a ticket on github for this point?
Skouat
Code Contributor
Posts: 1059
Joined: Mon Mar 10, 2008 5:30 pm
Location: France

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by bloodbane » Wed Feb 08, 2017 4:56 pm

I opened the ticket as requested. Thank you for the assistance you have provided so far. It is greatly appreciated!
bloodbane
Registered User
Posts: 7
Joined: Mon Feb 06, 2017 4:55 pm

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by Skouat » Wed Feb 08, 2017 8:21 pm

A new commit was pushed on Github.

Please can you update the extension ?
(same as previously... disable the ext, replace all files, enable the ext).
Skouat
Code Contributor
Posts: 1059
Joined: Mon Mar 10, 2008 5:30 pm
Location: France

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by bloodbane » Wed Feb 08, 2017 8:24 pm

It is updated. I will post the result as soon as I get another donation that way. Thank you!
bloodbane
Registered User
Posts: 7
Joined: Mon Feb 06, 2017 4:55 pm

Re: Not getting donors populated with phpBB 3.2 & ext 2.0.0-

by Skouat » Wed Feb 08, 2017 11:25 pm

As I seen your issue, you can disable/delete the test account ;)

Thanks in advance for your feedback.
Skouat
Code Contributor
Posts: 1059
Joined: Mon Mar 10, 2008 5:30 pm
Location: France