Dolibarr / dolibarr

Dolibarr ERP CRM is a modern software package to manage your company or foundation's activity (contacts, suppliers, invoices, orders, stocks, agenda, accounting, ...). it's an open source Web application (written in PHP) designed for businesses of any sizes, foundations and freelancers.
https://www.dolibarr.org
GNU General Public License v3.0
5.46k stars 2.79k forks source link

Bug non numeric with PHP 7.1.5 #6919

Closed Bagu closed 7 years ago

Bagu commented 7 years ago

Bug

When using Dolibarr 5.0.2 + PHP 7.1.5, there are many PHP Warning: A non-numeric value encountered

Environment

Suggested implementation

To correct some of them, i have done some changes : \comm\card.php line 69 \compta\bank\index.php, line 60 \compta\resultat\clientfourn.php, line 59 Replace : if ($page == -1) { $page = 0; } By : if ($page == -1 OR !is_numeric($page)) { $page = 0; }

\compta\paiement\cheque\card.php, line 56 Replace : if ($page < 0) { $page = 0 ; } By : if ($page < 0 OR !is_numeric($page)) { $page = 0 ; }

There are two other error in : \societe\class\societe.class.php line 1643 and \compta\ajaxpayment.php lige 69

But i don't know how to correct it.

SBA18 commented 7 years ago

I get the same error with Dolibarr v5.0.3 and I just disable the php error display in php.ini (displayError=Off)and no more error.

Bagu commented 7 years ago

It's not a solution... Let's close our eyes if a wall appear on the middle on the road --'

marcosgdf commented 7 years ago

Duplicate of #6712

eldy commented 7 years ago

Closed as duplicate. Als should be fixed with 6.0.1

ThieBurg commented 7 years ago

Hi folks,

I recently updated to 6.0.2 and still facing to the "non numeric" warnings with PHP 7.1 on accountancy_dispatch_customer pages. So returned back to 7.0. For sure, this is far to be ccritical.

In any case, congratulations to all contributors. You built/are duilding a fantastic ERP/CRM solution that allows me to develop my business.

Many tks again, Thierry