WordPress Tables reloaded problem

Avatar
  • Answered
I called on Friday with a request for support on a new WordPress site we have under development at pabred.org. The site contains a number of large tables which we are displaying using a plugin called WP Tables reloaded. I've used this plugin on a number of other sites with few problems but for some reason it's not working correctly on your server.

http://pabred.org/2011-pa-breds/

The tables are displayed as expected on the front end of the site but when we login to WordPress and attempt to edit the tables we are unable to save the changes. After attempting to save the changes the table is truncated to about 110 rows and we loss our table styling options and datables javascript features information.

It appears that this is a common problem and a number of people have posted questions on this topic to the wordpress support site.
http://wordpress.org/support/topic/plugin-wp-table-reloaded-cant-saveupdate-long-tables?replies=15

In the posted threads, the most frequent cause of the problem is the Suhosin Security plugin for php. (http://www.hardened-php.net/suhosin/)

In my conversation on Friday, the inmotion tech support person advised me that inmotion hosting doesn't use the Suhosin security plugin and adjusted some memory settings for the site in the hopes that this might solve the problem but it didn't help.

I understand that your not using Suhosin but I suspect that your server may have similar restrictions that are effecting the WordPress plugin. I'm hoping that you can take a closer look at the problem and find a solution for me.

The solution usually involves changing some settings in the php.ini file to adjust the restrictions on the POST variable limit. Other users of the plugin have reported that they were able to trouble shoot the problem by looking at the syslog.

"...it is not necessarily the size of the file that is the problem, but the number of rows in the table. If this is rather big, the "Suhosin" security extension for PHP sometimes stops the request so that WP-Table Reloaded can not save the table.
To solve this, "Suhosin" must be configured to be less strict."

"What it does: It limits the number of elements in an array to 64 (the value "suhosin.post.max_array_index_length" in your phpinfo.php).


In my plugin, every row basically is such an array element. This means: With Suhosin enabled with this value, you will not be able to Edit table with more than 64 rows.

Yes, please ask your host to set this value higher. (Actually the values "suhosin.post.max_array_index_length" or "suhosin.request.max_array_index_length" need to be set higher. Might be some others too, I don't really know.)
There also might be a possibility to do this yourself with a .htaccess file. Unfortunately I can't help with this, as I'm not familiar with that topic (and luckily Suhosin is not installed on my server.)

Sorry for the inconvenience, but there's nothing that I can do within the plugin to circumvent this :-("

"Hi,

I just ran into the same error. When checking the syslog I saw this event every time I tried to edit a large table:

Mar 4 17:09:22 *servername* suhosin[6974]: ALERT - configured POST variable limit exceeded - dropped variable 'table[data][48][0]' (attacker '88.*.*.*', file '/path/to/wp-admin/tools.php')

So obviously this is a "problem" (well, not really a problem) with suhosin. What I did was edit the file /etc/php5/apache2/conf.d/suhosin.ini (Debian Lenny). I set the values for

suhosin.post.max_vars
suhosin.request.max_vars

to a higher value and now everything works as expected ;)

Thanks for the great plugin, Tobias! ;) "

Avatar
BradM
Hi pabred6,

I'm not familiar with the exact issue that you're having, but I'm more than happy to help. In order to troubleshoot an issue like this, I would need to test it and attempt to replicate the problem.

If you would like another look at this problem, please email [email protected] with the following information:

1. Your site's URL and the login credentials to get into WordPress
2. The EXACT steps we can take to replicate the problem

If you decide to send the email, please be sure to post a comment at the bottom of this page so that we can look for your email.

Thanks,
- Brad