Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

max_input_vars .htaccess causing 500 error

I have a large form that is being updated in Wordpress with the plugin spitting out an error saying the max_input_vars is set to 1000. The site is on a shared host and tech support have updated the max_input_vars to 2000 in the php.ini, I have verified this.

I'm trying to add the following to the .htaccess to see if that helps the issue but receive a 500 error, probably bad syntax.

php_value max_input_vars 2000

Would I need to include this line of code in any particular format, am I missing something? Full .htaccess example below.

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

# END WordPress

#php_value max_input_vars 2000

Currently the max_input_vars is commented out so it doesn't cause the 500 error.

Any help would be much appreciated.

Cheers

like image 605
Bjorn Avatar asked Aug 01 '13 03:08

Bjorn


1 Answers

This one is working for me. Add this section to your .htaccess file in wordpress folder. That's all.

<IfModule mod_php5.c>

 php_value max_input_vars 5000

</IfModule>
like image 55
Taurion Avatar answered Sep 21 '22 16:09

Taurion