#1 2017-03-16 21:22:39


DataTables warning (table id = 'userList'), brand new Piwigo - A fix?

Yesterday, I installed Piwigo 2.8.6 on my server for testing before hopefully migrating my several thousand Gallery3 photos to it. In Admin Users/manage I got the following popup error message:

"DataTables warning (table id = 'userList'): DataTables warning: JSON data from server could not be parsed. This is caused by a JSON formatting error"

This happened only when the user search filter was empty.

Here's my Piwigo environment:
        Operating system: Linux
        Server: Apache 2.4.25 private SSL Virtual host
        Piwigo 2.8.6
        PHP: 5.6.9
        MySQL: 5.5.5-10.0.27-MariaDB
        Graphics Library: ImageMagick 6.8.9-8

I noticed that an error message was also logged each time by Apache:

[Thu Mar 16 ...] [php5:error] [...] PHP Notice:  Undefined index: sSearch in /.../piwigo/admin/user_list_backend.php on line 102, referer: .../piwigo/admin.php?page=user_list

I changed line 102 of user_list_backend.php from:

if ( $_REQUEST['sSearch'] != "" )


if ( isset($_REQUEST['sSearch']) && $_REQUEST['sSearch'] != "" )

and the problem completely disappeared, giving me the expected list of all users.
isset may not be to best choice of function to fix this, but it is working for me.

Regards to all, and thanks for what looks like a very promising gallery!



Board footer

Powered by FluxBB

github twitter facebook google+ newsletter Donate © 2002-2018 · Contact