Paypal payments not working (still)

Since a related query here by another user has not received any update since November I am starting again where he left off as I have the same problem. The original post was Paypal not working in OJS3.1 - #35 by Rahul_Arora. After running the composer because of missing Paypal files the error I get when trying to make a subscription payment is “A transaction error occurred. Please contact the journal manager for details.”. Can anyone help with this please?

Hi @nickpanes,

What specific release of OJS are you using?

Regards,
Alec Smecher
Public Knowledge Project Team

It is 3.101, installed on a linux server with PHP 5.6.33.

Hi @nickpanes,

This is most likely an issue with the Paypal API credentials you’ve configured OJS with. Did you try the suggestion in this other post?

Regards,
Alec Smecher
Public Knowledge Project Team

I am not familiar with API. V2.4.8 of OJS was set up using IPN. If I get API credentials from Paypal do I still need an IPN return address on the Paypal website profile?

An API certificate is provided in the format API Username, API Password, Signature. Are these entered under Distribution/ payments as Account name, Secret, Client ID?

Nick

Hi @nickpanes,

The PayPal API credentials take the place of the older IPN-based PayPal process.

Regards,
Alec Smecher
Public Knowledge Project Team

I decided to set up API again

For the avoidance of doubt when setting it up on the Paypal site there are three types: Pre-built payment solution, Braintree SDK integration, or NVP/SOAP API integration (Classic). Which option should I set this up through, the first? Also please see my question above as the credentials provided by Paypal do not match the lines to enter it under distribution / payments so I want to get that right.

Finally, can I assume the API page under my user profile is ignored?

Hi @nickpanes,

You’ll need to create REST API credentials. This can be done at Applications - PayPal Developer. If you’re creating the right credentials, they’ll match the nomenclature used in the PayPal setup in OJS.

The API entry under your user profile is not related to PayPal.

Regards,
Alec Smecher
Public Knowledge Project Team

Thank you for this I am making significant progress now. I made a live payment for a selected subscription. The payment went through but as the subscriber I never saw confirmation of the amount paid and instead of this or being returned to the journal site I was left with a blank screen. Not sure if the fix for this is in Paypal or OJS?

The blank page I was looking at was this one (with the domain changed):

http://mydomain.com/index.php/Transactions/payment/plugin/PaypalPayment/return?queuedPaymentId=18&paymentId=PAY-9K769895XJ574825TLKPOCZQ&token=EC-0B011352M1104290G&PayerID=HH6984GXZA2UN

Hi @nickpanes,

Not a problem – frankly it’s pretty easy to get lost in PayPal’s payment options.

Can you check your PHP error log to see if something appears there?

Regards,
Alec Smecher
Public Knowledge Project Team

This is the error we are getting:

PHP Fatal error: Call to undefined method RoleDAO::getJournalUsersRoleCount() in /data/htdocs/e/ojsdev/web/classes/subscription/SubscriptionAction.inc.php on line 53

Hi @nickpanes,

Try applying the patch at Fix notification error at https://forum.pkp.sfu.ca/t/paypal-payments-… · pkp/ojs@07a9aa4 · GitHub to resolve this.

Regards,
Alec Smecher
Public Knowledge Project Team

I am pleased to say that Paypal is working so a major obstacle to our implementation of 3.1 has been removed. Thanks for your help on this.

This thread can now be closed but having succeeeded only with a fresh install I now have another significant problem…

Nick