Not Solved prostats
#1
Not Solved
i add prostats plugin and i get this
https://gyazo.com/fa053358aa2414757b1fdf1d545b878
The following warnings occurred:

Warning [2] Illegal string offset 'Latest_posts' - Line: 1247 - File: inc/plugins/prostats.php PHP 7.1.2 (Linux)
File Line Function
/inc/plugins/prostats.php 1247 errorHandler->error
/inc/plugins/prostats.php 1837 ps_GetNewestPosts
/inc/plugins/prostats.php 1130 ps_MakeTable
/inc/class_plugins.php 139 prostats_run_index
/index.php 23 pluginSystem->run_hooks
Warning [2] Illegal string offset 'Date' - Line: 1252 - File: inc/plugins/prostats.php PHP 7.1.2 (Linux)
File Line Function
/inc/plugins/prostats.php 1252 errorHandler->error
/inc/plugins/prostats.php 1837 ps_GetNewestPosts
/inc/plugins/prostats.php 1130 ps_MakeTable
/inc/class_plugins.php 139 prostats_run_index
/index.php 23 pluginSystem->run_hooks
Warning [2] Illegal string offset 'Starter' - Line: 1257 - File: inc/plugins/prostats.php PHP 7.1.2 (Linux)
File Line Function
/inc/plugins/prostats.php 1257 errorHandler->error
/inc/plugins/prostats.php 1837 ps_GetNewestPosts
/inc/plugins/prostats.php 1130 ps_MakeTable
/inc/class_plugins.php 139 prostats_run_index
/index.php 23 pluginSystem->run_hooks
Warning [2] Illegal string offset 'Last_sender' - Line: 1262 - File: inc/plugins/prostats.php PHP 7.1.2 (Linux)
File Line Function
/inc/plugins/prostats.php 1262 errorHandler->error
/inc/plugins/prostats.php 1837 ps_GetNewestPosts
/inc/plugins/prostats.php 1130 ps_MakeTable
/inc/class_plugins.php 139 prostats_run_index
/index.php 23 pluginSystem->run_hooks
Warning [2] Illegal string offset 'Forum' - Line: 1267 - File: inc/plugins/prostats.php PHP 7.1.2 (Linux)
File Line Function
/inc/plugins/prostats.php 1267 errorHandler->error
/inc/plugins/prostats.php 1837 ps_GetNewestPosts
/inc/plugins/prostats.php 1130 ps_MakeTable
/inc/class_plugins.php 139 prostats_run_index
/index.php 23 pluginSystem->run_hooks
Warning [2] Illegal string offset 'Date' - Line: 1317 - File: inc/plugins/prostats.php PHP 7.1.2 (Linux)
File Line Function
/inc/plugins/prostats.php 1317 errorHandler->error
/inc/plugins/prostats.php 1837 ps_GetNewestPosts
/inc/plugins/prostats.php 1130 ps_MakeTable
/inc/class_plugins.php 139 prostats_run_index
/index.php 23 pluginSystem->run_hooks
Warning [2] Illegal string offset 'Latest_posts' - Line: 1340 - File: inc/plugins/prostats.php PHP 7.1.2 (Linux)
File Line Function
/inc/plugins/prostats.php 1340 errorHandler->error
/inc/plugins/prostats.php 1837 ps_GetNewestPosts
/inc/plugins/prostats.php 1130 ps_MakeTable
/inc/class_plugins.php 139 prostats_run_index
/index.php 23 pluginSystem->run_hooks
Warning [2] Illegal string offset 'Starter' - Line: 1351 - File: inc/plugins/prostats.php PHP 7.1.2 (Linux)
File Line Function
/inc/plugins/prostats.php 1351 errorHandler->error
/inc/plugins/prostats.php 1837 ps_GetNewestPosts
/inc/plugins/prostats.php 1130 ps_MakeTable
/inc/class_plugins.php 139 prostats_run_index
/index.php 23 pluginSystem->run_hooks
Warning [2] Illegal string offset 'Last_sender' - Line: 1357 - File: inc/plugins/prostats.php PHP 7.1.2 (Linux)
File Line Function
/inc/plugins/prostats.php 1357 errorHandler->error
/inc/plugins/prostats.php 1837 ps_GetNewestPosts
/inc/plugins/prostats.php 1130 ps_MakeTable
/inc/class_plugins.php 139 prostats_run_index
/index.php 23 pluginSystem->run_hooks
Warning [2] Illegal string offset 'Forum' - Line: 1363 - File: inc/plugins/prostats.php PHP 7.1.2 (Linux)
File Line Function
/inc/plugins/prostats.php 1363 errorHandler->error
/inc/plugins/prostats.php 1837 ps_GetNewestPosts
/inc/plugins/prostats.php 1130 ps_MakeTable
/inc/class_plugins.php 139 prostats_run_index
/index.php 23 pluginSystem->run_hooks



bump...
Reply
#2
Not Solved
Did you manage to get it to work because I have the same result
Reply
#3
Not Solved
I had it running on earlier version of php and then moved to php 7.1 and it exploded

I love the way prostats sits at the top of the forums and I think it is really cool the way it shows the information. I hope that it can be updated soon or something similar made available. Is there any latest thread plugins that allow placement above forums under header?
Reply
#4
Not Solved
I know this brings up an older post but I made a small fix for this problem if anyone comes across this.

Source:
https://github.com/crimson-med/ProstatsCorrected

would be cool if a mod could write on the first post that there is a solution.

Understanding the problem


If we look at the lines in question we have:

$active_cells = 1;

And

$active_cells["XXXX"]=1;

Where XXXX represent the different variables from the code.

The second statement is basically assigning the value 1 to the key XXXX

However if we look at the $active_cells declaration:

$active_cells = "";

We can see here that our variable is declared as a string and not an array

The Fix

The way to fix this is by declaring the $active_cells as an array

Replacing:

$active_cells = "";

By:

$active_cells = array("foo" => "bar","bar" => "foo");
Reply
#5
Not Solved
Doesn't work

(2018-01-10, 02:57 AM)Arzahel Wrote: I know this brings up an older post but I made a small fix for this problem if anyone comes across this.

Source:
https://github.com/crimson-med/ProstatsCorrected

would be cool if a mod could write on the first post that there is a solution.

Understanding the problem


If we look at the lines in question we have:

$active_cells = 1;

And

$active_cells["XXXX"]=1;

Where XXXX represent the different variables from the code.

The second statement is basically assigning the value 1 to the key XXXX

However if we look at the $active_cells declaration:

$active_cells = "";

We can see here that our variable is declared as a string and not an array

The Fix

The way to fix this is by declaring the $active_cells as an array

Replacing:

$active_cells = "";

By:

$active_cells = array("foo" => "bar","bar" => "foo");
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)