AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   HLstatsX:CE (https://forums.alliedmods.net/forumdisplay.php?f=156)
-   -   Fix for Daily Player Stats not working in PHP7 (https://forums.alliedmods.net/showthread.php?t=303486)

mlov420 12-09-2017 09:20

Fix for Daily Player Stats not working in PHP7
 
I have been having a problem for a while where Daily Player stats would not work. Only 'last month', 'last week', and full stats would work. It was an easy fix so I figured I should share it here for anyone else having the issue:

Go to install.dir/pages/players.php. On line 340 you should see this:

Code:

$minEvent = split("-", $dates[$rank_type-1]['eventTime']);
Change that line to this:

Code:

$minEvent = explode("-", $dates[$rank_type-1]['eventTime']);
Basically swap out 'split' for 'explode' as 'split' is no longer a function in PHP7. Save your file and that's it, daily player stats from the drop down menu should work as intended.


All times are GMT -4. The time now is 11:26.

Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.