Jump to content

max_input_vars 1000 [SOLVED]


Recommended Posts

I have been trying to change the language of this page to Spanish. http://elektrozales.com/es/

I can’t change "ADD TO CART" to "AÑADIR AL CARRITO". I have been trying for days, I have translated and all, but when i click on "translate back-Office" it says 1000 de max_input_vars.

and you need 4654, ask your hosting provider to increases it.

 

I just called godaddy, but they said me they don’t have that file, and I should create it, but I don’t know how.

 

I just printed my phpinfo and it said that it already exists in this place: /web/conf/php5.ini but I can’t find it, can some 1 help me?

 

I will appreciate any help, thank so much and sorry for my English, I am not native English speaker

there is my php info: http://elektrozales.com/phpinfo.php

Edited by elektrozales (see edit history)
  • Like 2
Link to comment
Share on other sites

This should be in your php.ini file under resource limits:

Here is an example:

 

max_execution_time = 1000	 ; Maximum execution time of each script, in seconds
max_input_time = -1 ; Maximum amount of time each script may spend parsing request data
memory_limit = 1024M	  ; Maximum amount of memory a script may consume (32MB)
max_input_vars = 10000;

  • Like 2
Link to comment
Share on other sites

That may be a hidden file call Go Daady back and tell them you need the max_input_vars increased in your PHP,ini file.

In the root folder of your FTP account do you see a web folder.

Funny how some host are, with mine I am able to edit my PHP.ini file right from the control panel and even switch between 5.2 and 5.3.

Funny thing was though with PHP 5.3 even when I changed the max_input I still received this message I switched back to 5.2 and no more errors.

Here is why 5.2 has no such variable that started with 5.3.

 

 

You can create a file named php5.ini and place this code inside then upload to the root of your domain.and see if it helps

 

 

; How many GET/POST/COOKIE input variables may be accepted

max_input_vars = 5000

 

 

OR

 

You could also try adding this to your .htaccess file: (do one or the other)

[color=#3F3E29][font=Arial, Helvetica, sans-serif]php_value max_input_vars 5000[/font][/color]

  • Like 6
Link to comment
Share on other sites

That may be a hidden file call Go Daady back and tell them you need the max_input_vars increased in your PHP,ini file.

In the root folder of your FTP account do you see a web folder.

Funny how some host are, with mine I am able to edit my PHP.ini file right from the control panel and even switch between 5.2 and 5.3.

Funny thing was though with PHP 5.3 even when I changed the max_input I still received this message I switched back to 5.2 and no more errors.

Here is why 5.2 has no such variable that started with 5.3.

 

 

You can create a file named php5.ini and place this code inside then upload to the root of your domain.and see if it helps

 

 

; How many GET/POST/COOKIE input variables may be accepted

max_input_vars = 5000

 

 

OR

 

You could also try adding this to your .htaccess file: (do one or the other)

[color=#3F3E29][font=Arial, Helvetica, sans-serif]php_value max_input_vars 5000[/font][/color]

 

I called back to Godaddy, they said me they dont know PHP so well, and they are not able to code anything...

what i should do?

 

I added the code that u said to the .htaccess file, but still dont work, i think i should create this file, but how i can i do that? and should i place it in the root? or where?

 

thanks for your fast replys

Link to comment
Share on other sites

I made the file for you just download to your computer then upload to the root folder of your shop.

 

before uploading change the name to php5.ini, the forum does not allow .ini files to be uploaded.

 

 

 

 

Thank you so much now i can translate, =D

Link to comment
Share on other sites

  • 2 months later...

Hi,

I have the same problem.

I have uploaded the file php5.ini in the root of the shop but I have the same error.

Warning: Your PHP configuration limits the number of fields in the form of post:

1000 max_input_vars.

Please ask your provider to increase this limit to a minimum of 1632 or translate the file manually ..

what's wrong ?

My php version is PHP 5.3

my shop is hosted on go daddy.

Thank you in advance

Have a nice day

MAXC

Edited by makuweb (see edit history)
Link to comment
Share on other sites

  • 1 month later...

That may be a hidden file call Go Daady back and tell them you need the max_input_vars increased in your PHP,ini file.

In the root folder of your FTP account do you see a web folder.

Funny how some host are, with mine I am able to edit my PHP.ini file right from the control panel and even switch between 5.2 and 5.3.

Funny thing was though with PHP 5.3 even when I changed the max_input I still received this message I switched back to 5.2 and no more errors.

Here is why 5.2 has no such variable that started with 5.3.

 

 

You can create a file named php5.ini and place this code inside then upload to the root of your domain.and see if it helps

 

 

; How many GET/POST/COOKIE input variables may be accepted

max_input_vars = 5000

 

 

OR

 

You could also try adding this to your .htaccess file: (do one or the other)

[color=#3F3E29][font=Arial, Helvetica, sans-serif]php_value max_input_vars 5000[/font][/color]

hi presta

i registered myself just because to say thank you.this peice of code helped me in increasing variables in menu items in word press.i will definately share your link on wordpress platform.thanks and i will follow this forum onwards............

  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...
  • 4 weeks later...

Hello everyone. Thanks for sharing this topic. I have the same problem with translations, but my provider told me that it is not possible to increase the value!! What do I do now? 

 

Probably the only workable solution is to replicate your shop on a localhost running on your computer.  (search forum on how to do this or open a new topic).  This will allow you to set you localhost values so that you can make the changes, then you  would ftp  those changes to your remote..

 

The better option is to find another hosting company.

  • Like 1
Link to comment
Share on other sites

  • 2 weeks later...

Probably the only workable solution is to replicate your shop on a localhost running on your computer.  (search forum on how to do this or open a new topic).  This will allow you to set you localhost values so that you can make the changes, then you  would ftp  those changes to your remote..

 

The better option is to find another hosting company.

 

Thank you El Patron for advice. I replicated the shop on localhost as you suggested. I had done that before, so it wasn't such a big problem. Now I can access all my translations. So thanks again. 

  • Like 1
Link to comment
Share on other sites

  • 1 month later...

I have been through this problem  with a number of different hosts. With different host companies, one of the following always worked for me:

 

  • Ask your hosting panel to make the change to the php
  • Or add the following line to your htaccess (without quotes): "php_value max_input_vars 4000"
  • Or add the following line to your htaccess (without quotes): "php_flag max_input_vars 4000

However, I am currently working on a site hosted on GoDaddy (helpful support but absolutely useless hosting) and the issue is not resolving.

Link to comment
Share on other sites

  • 2 weeks later...

Just wanted to add this: For me the solution was to edit the php.ini file located in the etc/php5/apache2-folder. I guess the location can be different from host to host. I have a cloud-vps server btw.

 

this is a very good point...it's all about location location location...oh, and putty....

 

for anyone that wants to know where their php.ini is located and/or pathing to any and all .ini's, get this free module...

 

http://www.prestashop.com/forums/topic/278164-free-module-display-php-environment-13-14-15/

Link to comment
Share on other sites

  • 1 month later...

I made the file for you just download to your computer then upload to the root folder of your shop.

 

before uploading change the name to php5.ini or php.ini the forum does not allow .ini files to be uploaded.

 

 

attachicon.gifphp.txt

 

 

 

I would like to thank and inform you that the above file on this date still is working very well.

I put the file in / public_html as the name php.ini

very sheltered by tdr170 file

sorry my english.

 
I forgot to mention. xD
my hosting is godaddy linux
Edited by psycki (see edit history)
  • Like 2
Link to comment
Share on other sites

  • 3 weeks later...
  • 1 month later...

What filename does my PHP initialization file (php.ini) need to use?

Date Submitted: 1-31-2014

PHP initialization files can manage form, server, and environmental variables as well as server-side cookies, temporary directories, error display, and error logging.

The file name your PHP initialization must use depends on the type of hosting account you have. For more information, see What type of hosting account do I have?

Type

Filename

 

Web Hosting - Windows
with PHP 5.4 (info) .user.ini

 

 All Other Web Hosting php5.ini

 

*cPanel .user.ini

 

Plesk .user.ini

 

Managed WordPress php.ini

 

* You must have a .user.ini file in the Web root of each domain to modify its PHP settings.

Web Hosting accounts running Windows with IIS 6 do not support PHP and therefore do not support PHP initialization files.

Edited by jose266x (see edit history)
Link to comment
Share on other sites

  • 1 month later...
  • 4 weeks later...

Just be aware that in PHP 5.2.38 there is no such option "max_input_vars" to change, at least do a search and look into the resource limits category... any idea?

 

Try to add it on, no change at all, I am hosting my own server and have full access to it, and I am running on Windows Server 2012 R2 version newest. with IIS 8.0

Link to comment
Share on other sites

  • 1 month later...

Sorry to raise that issue again. I'm having a hard time here.  Tried them all: change the .haccess, php.ini, so forth. 

 

I use PHP2 (changed from PHP3 as suggested in some forums) and the configuration is there as max_input_vars=1000

 

Question is: Is that possible that the host prevent me from overriding this parameter in anyway?

 

In times, there was no php.ini file in my directories, coming from the host. I created my own. 

 

Thanks in advance.... Really needing to solve this.

Link to comment
Share on other sites

Sorry to raise that issue again. I'm having a hard time here.  Tried them all: change the .haccess, php.ini, so forth. 

 

I use PHP2 (changed from PHP3 as suggested in some forums) and the configuration is there as max_input_vars=1000

 

Question is: Is that possible that the host prevent me from overriding this parameter in anyway?

 

In times, there was no php.ini file in my directories, coming from the host. I created my own. 

 

Thanks in advance.... Really needing to solve this.

 

yes, it's very possible that your hosting is limiting this.

 

use this free module to see what if any affects your changes have made

 

http://www.prestashop.com/forums/topic/278164-free-module-display-php-environment-phpinfo-back-office/

 

if your changes are not seen, then contact your hosting company.  If they can not change then move to new hosting as having xlate (in fact control of all content) is very important.

Link to comment
Share on other sites

yes, it's very possible that your hosting is limiting this.

 

use this free module to see what if any affects your changes have made

 

http://www.prestashop.com/forums/topic/278164-free-module-display-php-environment-phpinfo-back-office/

 

if your changes are not seen, then contact your hosting company.  If they can not change then move to new hosting as having xlate (in fact control of all content) is very important.

 

Run it and still 1000 even with php.ini set at 5000 at the admin folder.... 

 

This means I'm moving?  :(

Link to comment
Share on other sites

Did you contact your hosting company?

Yes, they said they "can't change" the configuration. I should try via .htaccess. But I don`t even know if they know what I was talking about. 

 

Just submitted another request, maybe I get a better "tech" guy over there. I never used this host before. And I always managed to correct this input var issue quite easily before. 

 

Any ways, gracias El Patron!

  • Like 1
Link to comment
Share on other sites

Yes, they said they "can't change" the configuration. I should try via .htaccess. But I don`t even know if they know what I was talking about. 

 

Just submitted another request, maybe I get a better "tech" guy over there. I never used this host before. And I always managed to correct this input var issue quite easily before. 

 

Any ways, gracias El Patron!

 

con mucho gusto, please let us know how this works out for you.

Link to comment
Share on other sites

El Patron, 

 

I found another host and asked them about this issue. The answer was "you can change most of the settings blah blah blahb via .htaccess"

 

Is there a way that I can "test" this before uploading the entire store? The module you suggested worked like a charm, but only under prestashop's environment. 

 

Thanks for you help.... 

Link to comment
Share on other sites

Never mind, I found the solution with phpinfo()

 

I'm resistent to changing host right now.... Maybe you can give me some light here. 

 

My .htaccess file has this solely info:

 

# Do not remove this line or mod_rewrite rules and search engine friendly URLs will stop working
RewriteBase /
 
*then I would have to add:*
 
php_flag max_input_vars 4000
 
I wonder whether or not I'm missing some "/" or ";" in this thing. What about that slash in the end of the line? Does it stop the following commands?
Link to comment
Share on other sites

  • 2 weeks later...

we don't know your hosting environment configuration

some hosts blocks possibiltiy to deal with php configuration via php.ini / htaccess file

in cases like that it's worth to contact with host and ask about possibilities in php environment configuraiton

Link to comment
Share on other sites

I have just solve this problem using solution from here: http://lessons-joomla.ru/uroki/khosting-i-domeny/97-ustanovka-i-nastrojka-lokalnogo-servera-denver-denwer.html. Add the following code to the end of .htaccess file in Prestashop folder:

 

<IfModule php5_module>
php_value max_input_vars 50000
php_value suhosin.request.max_vars 50000
php_value suhosin.post.max_vars 50000
</IfModule>

  • Like 3
Link to comment
Share on other sites

I have just solve this problem using solution from here: http://lessons-joomla.ru/uroki/khosting-i-domeny/97-ustanovka-i-nastrojka-lokalnogo-servera-denver-denwer.html. Add the following code to the end of .htaccess file in Prestashop folder:

 

<IfModule php5_module>

php_value max_input_vars 50000

php_value suhosin.request.max_vars 50000

php_value suhosin.post.max_vars 50000

</IfModule>

 

Thanks !

 

Works fine.

Link to comment
Share on other sites

I used the above method on my Hostinger.com server, unfortunatelly it doesn't work.

I contacted with hostinger service and they confirmed that it's possible by .htaccess modification.

Any suggestions, please?

Link to comment
Share on other sites

Already given by @rumit

 

Try to add to the top of your .htaccess (inside prestashop folder)

##

# max_imput_var = 1000 default. Increased to 5000
<IfModule php5_module>
 php_value max_input_vars 5000
 php_value suhosin.request.max_vars 5000
 php_value suhosin.post.max_vars 5000
</IfModule>

## END ##

etc...
Edited by myselfidem (see edit history)
Link to comment
Share on other sites

You're right !

 

Tested on my Computer with PrestaShop installed on local mode works fine ...But not on line !!! :blink:

 

and you're also on the same hosting account?

 

 

btw. why not to ask hoster about that? i mean, if it is possible to alter php configuration via htaccess

why not to ask them HOW TO DO THAT? it's worth to because you use solution that works on local, but it doesnt work on remote

 

so it's something wrong with hosting, not local installation ;)

Link to comment
Share on other sites

and you're also on the same hosting account?

 

 

btw. why not to ask hoster about that? i mean, if it is possible to alter php configuration via htaccess

why not to ask them HOW TO DO THAT? it's worth to because you use solution that works on local, but it doesnt work on remote

 

so it's something wrong with hosting, not local installation ;)

 

My "feeling" is that the people in charge of the tickets don't know much. The answer they gave me that "I could try" to change on .htaccess. 

 

Possibly there are other variables that can be changed that way. And, very likely, they don't know which and how LOL. 

 

Oh, and of course, I was using their free hosting. Meybe you can change these things under a paid hosting. 

Link to comment
Share on other sites

Took me a while to figure out the exact steps to get this to work.  

I'm using a godaddy shared Linux hosting account (Deluxe in case you were wondering)

 

1) I have multiple domain names as add on domains to my hosting account.  The current domain that I am working on is not the primary domain on the hosting account, but an add-on which has it's own root folder in my file manager (ex. webroot/domain.com/)  

2) I spent quite a bit of time dropping in php.ini as well as php5.ini into my domain's root folder with none of them working.  Furthermore, I installed prestashop into "webroot/domain.com/shop/" which is where prestashops .htaccess file is located.

3) In order for me to get this to work i had to go back to my webroot folder (which is outside of my domain.com's root folder) and put my php5.ini there.  Note: php.ini will not work 

4) I then needed to go into my hosting account and click on "System Processes" then click the button "End Web" for my php5.ini file to take effect.  

 

And in case you were wondering which values I added to my php5.ini file... 

 

suhosin.post.max_vars = 4252;
suhosin.request.max_vars = 4252;
max_input_vars = 10000;
 
That was it.  I verified that the changes took place by using a phpinfo() file and everything now seems to work.
 
Hope this helps someone!
Link to comment
Share on other sites

  • 1 month later...

I made the file for you just download to your computer then upload to the root folder of your shop.

 

before uploading change the name to php5.ini or php.ini the forum does not allow .ini files to be uploaded.

 

 

attachicon.gifphp.txt

Worked like a charm thank you!!! 

  • Like 1
Link to comment
Share on other sites

  • 1 month later...

I have just solve this problem using solution from here: http://lessons-joomla.ru/uroki/khosting-i-domeny/97-ustanovka-i-nastrojka-lokalnogo-servera-denver-denwer.html. Add the following code to the end of .htaccess file in Prestashop folder:

 

<IfModule php5_module>

php_value max_input_vars 50000

php_value suhosin.request.max_vars 50000

php_value suhosin.post.max_vars 50000

</IfModule>

 

Thank You for this solution. Works perfect :)

Highly recomended solution for polish hosting provider nazwa.pl

Link to comment
Share on other sites

  • 2 months later...

Hi, same problem here. I am on inmotion hosting

I made following changes on ph.ini file, but still not working.

 

max_execution_time = 30     ; Maximum execution time of each script, in seconds
max_input_time = 60 ; Maximum amount of time each script may spend parsing request data
memory_limit = 512M      ; Maximum amount of memory a script may consume (32MB)
max_input_vars = 5000
suhosin.post.max_vars = 5000
suhosin.request.max_vars = 5000
 
Should I try to increase it?
Link to comment
Share on other sites

Hi Vekia,

The following message is displaying under localization > translations > installed modules translations

 

Warning! Your PHP configuration limits the maximum number of fields allowed in a form
1000 for max_input_vars.
Please ask your hosting provider to increase this limit to 3725 at least, or you will have to edit the translation files.

Link to comment
Share on other sites

  • 4 weeks later...

Hi All,

 

I've had the same issue and have a provider that is very cooperative to change the value.

However: I was told that increasing the value also has a downside in performance!

 

I have noticed that if I get the message in Translation and I restart my computer, the message is gone and I can do the translations.

So it's sometimes caused because of full cach. My value is at 4000!

Link to comment
Share on other sites

It becomes a performance and security issue, since your server will now allow form submissions to contain 4000 parameters.  Hackers will try to use that as an opportunity to DDOS your server or find a way in.

 

Therefore you should not allow this globally.  You should configure it in a way that it will only apply to your back office folder.  Tell that to your hosting provider and they should understand.

Link to comment
Share on other sites

  • 1 month later...

Unfortunately none of solutions above worked for me. I've almost copy entire database into localhost and try there my luck, but i found solution here:
 
http://dh42.com/blog/speed-prestashop-php-ini/
 
I still can't belive it works, after hours and hours of trying to solve this up.
I have GoDaddy hosting and i've tried this method:
 
- put info.php in root folder
- put php.ini file in same root folder (you need to create it from blank, detailed information in link i've posted):

[PHP]
memory_limit = 2048M
max_execution_time = 1000;
max_input_time = -1;
post_max_size = 15M;
upload_max_filesize = 15M;
max_input_vars = 10000;
suhosin.get.max_vars = 10000;
suhosin.post.max_vars = 10000;

(you can change vars form 10000 to your number)

- kill all php processes in GoDaddy cPanel !!!

WOOOOOHAAA works like a german car :P

Link to comment
Share on other sites

  • 3 months later...

Have same problem,  but not able to edit php.ini
 

After edit .htaccess   i get a 404 page.

 

below  part of htaccess   what do I do wrong ?
 

#blockguestbook - not remove this comment 
RewriteRule ^(.*)guestbook/?$ /webshop/modules/blockguestbook/blockguestbook-form.php [QSA,L] 
#blockguestbook
 
# ~~start~~ Do not remove this comment, Prestashop will keep automatically the code outside this comment when .htaccess will be generated again
# .htaccess automaticaly generated by PrestaShop e-commerce open-source solution
 
<IfModule mod_security.c>
SecFilterEngine Off
SecFilterScanPOST Off
</IfModule>
 
<IfModule mod_rewrite.c>
<IfModule mod_env.c>
SetEnv HTTP_MOD_REWRITE On
</IfModule>
 
RewriteEngine on
 
# aangepast prestashop 28-6-2015
php_flag max_input_vars 4000
 
 
#Domain: www.hobby-benodigdheden.nl
RewriteRule . - [E=REWRITEBASE:/webshop/]
RewriteRule ^api$ api/ [L]
 
RewriteRule ^api/(.*)$ %{ENV:REWRITEBASE}webservice/dispatcher.php?url=$1 [QSA,L]
Link to comment
Share on other sites

  • 2 weeks later...
  • 5 months later...
  • 1 month later...
  • 1 month later...

I made the file for you just download to your computer then upload to the root folder of your shop.

 

before uploading change the name to php5.ini or php.ini the forum does not allow .ini files to be uploaded.

 

 

attachicon.gifphp.txt

Hello I am having this same issue. My provider told me I can "increase this by creating your own php.ini file in the public_html folder."

 

I tried to download the file you attached but I don't think it is there anymore.

Link to comment
Share on other sites

  • 3 weeks later...

Hello,

 

I have the same problem. I am using prestashop 1.6.1.4., php 5.4 on my server, and I am using polish hosting provider home.pl 'Business Cloud Starter'

after editing my file /public_html/prestashop/.htaccess (atributes777) and adding these lines to this file:

<IfModule php5_module>
php_value max_input_vars 2000
php_value suhosin.request.max_vars 2000
php_value suhosin.post.max_vars 2000
</IfModule>

nothing happends and still i cant translate my site.

 

Does anyone from Poland(home.pl) had the same situation? Many thanks for the reply. Greetings.

Edited by Nieuchwytny_Uchwyt (see edit history)
Link to comment
Share on other sites