Support » Plugin: Quick Paypal Payments » Bug / Error with PHP 7.1

  • After upgrading to PHP 7.1 – seeing this error in error.log

    PHP Warning: A non-numeric value encountered in quick-paypal-payments.php on line 664

    The line in that seems to be throwing off the error is this

    $values['producttotal'] = $values['producttotal'] + $p +$h;

    The payment form seems to be functioning – I don’t see any problem and we have received payments via the form since the upgrade.

    This appears to be a fairly common issue with PHP 7.1

Viewing 3 replies - 1 through 3 (of 3 total)
  • Just to add to the above report, I also get the same error, same file, for line 655.

    Plugin Author aerin


    I’m not sure how to fix this. All 4 variables are numbers (or the code wouldn’t work). It’s possible the we need to set each of them to zero so PHP thinks they have a numeric value.

    But I’m clutching at straws here.

    I don’t have a clue either, but I know that his is a very common error for PHP 7.1 (for many themes and plugins). If you Google the error you’ll find many reports.

    One suggestion on how to fix is by prefixing the render call with an @ (Suggested at I know that worked for a different plugin on the site with a similar issue, but I don’t know if that would work in all cases.

    I rolled back to PHP 7.0 on the site where I am reporting it, so no ongoing issue.

    I just wanted to report it because going forward, you can probably expect more widespread adoption of PHP 7.1 — and I am just letting developers know when I spot an issue that doesn’t seem to be reported previously. So you probably will want to test everything on PHP 7.1 going forward (as well as PHP 7.0 and PHP 5.6)

    I’ve been a web developer for 21 years… so I definitely understand the frustrations when platform and framework upgrades mess up your coding. You work for hours upon hours to get something working correctly, and then the powers that be come along and decide to deprecate some bit of code you are relying on.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Bug / Error with PHP 7.1’ is closed to new replies.