When running overall stats under PHP 8.0 I see the following error which I can't fix:
Fatal error: Uncaught TypeError: array_multisort(): Argument #1 ($array) must be an array or a sort flag in stats.inc.php (243
Also on line 326.
Code on 243 stats.inc.php
array_multisort($osResultArray,SORT_DESC);
$osTotal = array_sum($osResultArray);
and
stat_details.php(326): individualStatsByOS(0, 'hits', '100%') #2 {main} thrown in stat_details.php
Code on 326 in the stat_details.php
individualStatsByOS($pid,$type,$statsTableWidth);
individualStatsByBrowser($pid,$type,$statsTableWidth);
Anyone an idea ?
Thank you for providing feedback and discovering the error situation(s).
Corrections will be made in a day or two and be included in an updated version (1.6.14).
I have replaced the files from the CPG 1.6.14 package.
No errors but the stats page is totally empty.
Tried this before upgrading to PHP 8.0 and before it worked correctly (lot of stats information)
Any thing else I am missing ?
For now, make the change below. Work will be scheduled in this area at a later time for the next release.
In file stat_details.php, change line 39 from
$pid = 0;
to
$pid = '';
Quote from: ron4mac on October 05, 2021, 06:46:28 PM
For now, make the change below. Work will be scheduled in this area at a later time for the next release.
In file stat_details.php, change line 39 from
$pid = 0;
to
$pid = '';
Yes it fixed the issue.
Thanks