• Resolved marcop68

    (@marcop68)


    The plugin doesn’t seem to work, or connect correctly to PayPal. I’ve installed it, linked it to a business PayPal account and generated a form, which is displayed correctly. However, when clicking on the payment button, nothing happens and I get the “Oops, got a problem here”. Sadly, there is no message anywhere on what the “problem” may. With “nothing happens” I mean that the PayPal pop-up doesn’t display.

    If I configure the plugin to use the sandbox, then the PayPal plugin shows very quicky, then closes and the same error message appear.

    If I enable WordPress debug log, I can see a few errors about this plugin:

    [21-May-2020 13:13:01 UTC] PHP Notice:  Undefined variable: border in /home/.../wp-content/plugins/quick-paypal-payments/legacy/quick-paypal-payments.php on line 2562
    [21-May-2020 13:13:01 UTC] PHP Notice:  Undefined index: couponblurb in /home/.../wp-content/plugins/quick-paypal-payments/legacy/quick-paypal-payments.php on line 687
    [21-May-2020 13:13:01 UTC] PHP Notice:  Undefined variable: couponcode in /home/.../wp-content/plugins/quick-paypal-payments/legacy/quick-paypal-payments.php on line 694
    [21-May-2020 13:13:01 UTC] PHP Notice:  Undefined index: reference in /home/.../wp-content/plugins/quick-paypal-payments/legacy/quick-paypal-payments.php on line 756
    [21-May-2020 13:13:01 UTC] PHP Notice:  Undefined index: couponblurb in /home/.../wp-content/plugins/quick-paypal-payments/legacy/quick-paypal-payments.php on line 687
    [21-May-2020 13:13:01 UTC] PHP Notice:  Undefined variable: couponcode in /home/.../wp-content/plugins/quick-paypal-payments/legacy/quick-paypal-payments.php on line 694
    [21-May-2020 13:13:01 UTC] PHP Notice:  Undefined index: reference in /home/.../wp-content/plugins/quick-paypal-payments/legacy/quick-paypal-payments.php on line 756
    [21-May-2020 13:13:01 UTC] PHP Notice:  Undefined index: couponapplied in /home/.../wp-content/plugins/quick-paypal-payments/legacy/quick-paypal-payments.php on line 1293
    [21-May-2020 13:13:03 UTC] PHP Notice:  Undefined variable: currency in /home/.../wp-content/plugins/quick-paypal-payments/legacy/quick-paypal-payments.php on line 1842

    I don’t use any coupons… By editing the plugin code and removing the “Undefined variable” errors, the plugin still doesn’t work.

    Is it something to do with PayPal?

Viewing 15 replies - 1 through 15 (of 15 total)
  • Plugin Author fullworks

    (@fullworks)

    What ever your issue is, it isn’t related to notices and warnings, notices and warning are simply notices to developers and do not impact functionality.

    See https://fullworks.net/docs/plugins-general/troubleshooting-plugins-general/php-notices-and-warnings/

    I can’t really help you debug further without detailed access as there are so many settings it could be anything. And debugging the free version in individual sites is not a service I offer. If you can identify a specific error I will endeavour to fix it.

    I can say that in a ‘vanilla site’ the plugin works fine when set up, you can see it working here https://fullworks.net/docs/quick-paypal-payments/demos-quick-paypal-payments/

    Have you check the console log for javascript errors?

    Thread Starter marcop68

    (@marcop68)

    There are no Javascript errors: in Chrome I have only the PayPal cookie warning with “Samesite” while in Firefox and IE I don’t have (of course) the warning but I still haven’t the popup.
    In Sandbox mode I have some debug messages from PayPal (a console.log(…) of an object) but no joy…
    I understand you cannot/want provide help for a free plugin (I have the suspicion the problem may be due to my theme, Shapely), but as my site is live, I won’t be using your plugin, sorry, and rather go to WP PayPal which is working out of the box.

    Plugin Author fullworks

    (@fullworks)

    It is a shame you can’t identify the specific error.

    I guess you don’t have a test system you can check your theme theory out on.

    Can I ask, how many fields are you using on the form – as the error is an error return from PayPal it is within the bounds of possibility that a specific field or option is cause a reject from paypal.

    Have you tried with the most simple form possible – or have you complex options?

    In any case I’m glad you have found a solution that works for you.

    Thread Starter marcop68

    (@marcop68)

    The form I tried to use was a “read-only” one. I generate programmatically from my own plugin this shortcode:

    [qpp amount="GBP100" form="EMHC" id="My Test Product"]

    The EMHC form displays only the id (My Test Product) and the price (both were displaying correctly). Curiously, if the form was not read-only, the <input> box for the product was not filled in with the id of the shortcode, but used the default one.

    It’s a bit of a mystery, many thanks for your time: perhaps you could consider having a way to export the form for testing/checking at your end, and perhaps create a log for any PayPal error.

    Unfortunately, I don’t have a test system to work with, I’m afraid.

    All the best, thank you!

    Plugin Author fullworks

    (@fullworks)

    I’m currently totally re-writing this plugin, as I inherited the plugin from the original developer that no longer could look after it.

    The existing code line has a lot of history and so is not structured to easily support and enhance. It is quite a big effort to rebuild it, I do hope it will be worth the effort in the end

    Plugin Author fullworks

    (@fullworks)

    Just trying to understand your prior post

    so I think you are saying that you were not calling the shortcode from a page – but from a do_shortcode call in another plugin?

    Thread Starter marcop68

    (@marcop68)

    That’s correct: the big advantage of your plugin is that the shortcode can be created dynamically. In my case, I have a plugin that extends a commercial WP plugin (that doesn’t handle PayPal). My plugin publishes a shortcode (which of course I’ve put on a page, called by the other plugin) which reads the data from the other plugin and generates a call to the [qpp] shortcode. Essentially, I do a:
    echo apply_filters('the_content', "[qpp .....]");
    in my shortcode.

    The plugin I’m using now (WP PayPal) does the same think as qpp does, but rather than opening the pop-up (which I would greatly prefer), opens a PayPal page.

    I spent all morning looking at the qpp code and I can sympathize with you and the challenges in rewriting the plugin!!! ??

    Plugin Author fullworks

    (@fullworks)

    Yes look in the folder – legacy which is where I’m holding the legacy code.

    But you are confusing me about the popup… if there is a popup feature I haven’t found it yet!

    have you tried do_shortcode

    do_shortcode('[.....]');

    The rewrite will have a REST-API for the submission, so in theory people will be able to submit ‘headlessly’. But there is a lot of work to be done.

    Thread Starter marcop68

    (@marcop68)

    The “popup” I mean is what you get – for example – on eBay when you pay for your purchase with PayPal… not sure what is its technical term ?? I understand that the folder “legacy” is where you have the old code, but it seemed to be where qpp was running its code on my setup (at least, all the errors/warnings I could see were from that file).

    I didn’t try to call the do_shortcode as my content for the apply_filters() contains other dynamic text that I have to generate in my shortcode, unfortunately.

    What I did was to have a test page with the

    [qpp amount="GBP100" form="EMHC" id="My Test Product"]

    shortcode directly in it and I had the same behaviour as described in my OP.

    Plugin Author fullworks

    (@fullworks)

    I’m going to test it but I think I can see your issue

    Plugin Author fullworks

    (@fullworks)

    As I can replicate the issue I should now be able to fix it.

    Plugin Author fullworks

    (@fullworks)

    OK fixed in the next version 5.7.1

    You don’t want to know the bug ??

    Thread Starter marcop68

    (@marcop68)

    That’s great, thank you very much! I’ve seen the bug in the source ?? it’s “one of those things” ?? ! Well spotted, I would not have been able to find it without spending days!

    • This reply was modified 4 years, 6 months ago by marcop68.
    Thread Starter marcop68

    (@marcop68)

    PS: I confirm it’s now working! Many thanks for the quick turnaround!

    Plugin Author fullworks

    (@fullworks)

    Yes, it was difficult to see – the power of xdebug & PHPstorm to be able to step through..

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘Plugin not Working (May 2020)’ is closed to new replies.