Increase the maximum number of characters in the fields in PHP
This article has been created by an automatic translation software. You can view the article source here.
fr:Augmenter le nombre maximal de caractères des champs en PHP
he:הגדל את המספר המרבי של תווים בשדות ב- PHP
ja:PHP でフィールドの文字の最大数を増やす
ar:زيادة الحد الأقصى لعدد الأحرف في الحقول في بي إتش بي
zh:PHP 中的字段中的字符数增加
ro:Creşte numărul maxim de caractere în câmpurile în PHP
ru:Увеличить максимальное количество символов в полях в PHP
pl:Zwiększ maksymalną liczbę znaków w pola w PHP
de:Erhöhen Sie die maximale Anzahl von Zeichen in Feldern in PHP
nl:Verhoog het maximum aantal tekens in velden in PHP
it:Aumentare il numero massimo di caratteri nei campi in PHP
pt:Aumentar o número máximo de caracteres em campos em PHP
es:Aumentar el número máximo de caracteres en campos en PHP
en:Increase the maximum number of characters in fields in PHP
Introduction
You get the following error ?
Attention, votre configuration PHP limite le nombre maximum de champs d'un formulaire *1000* pour max_input_vars. Veuillez contacter votre hébergeur pour augmenter cette limite à au moins 3000, ou vous devrez modifier les fichiers de traduction.
Ceci est dû au paramètre max_input_vars du fichier php.ini non ou mal configuré.
Solution
Dedicated server
If you have access to the configuration of the machine for example SSH access, here is the procedure to be applied to solve the problem.
Locate the php.ini file
If you do not know the path to the php configuration file, please follow these instructions :
- If you do not know the path of the configuration file, create a php file in the folder of your web site containing this
<? phpinfo(); ?>
- Then, navigate your browser to the address of the file and read the location.
- Another solution, if the first does not work, is to type the following command in your terminal connected to your machine.
php -i | grep 'php.ini'
- You should receive a result similar to this one
Loaded Configuration File => /usr/local/lib/php.ini
Edit the php.ini file
Once the localized configuration file we can change it in order to increase the limit.
- To connect to the machine through the ssh protocol
ssh utilisateur@ma_machine
- You will be asked your password.
- Once connected, move you in the php configuration file, more often
cd /etc/php5/
- Now that you're in the php configuration file, edit the php.ini file
vi php.ini
- Find and edit the next line
# max_input_vars = 1000
- Necessary to dé-commentez the line or add it if it was not present in the file.
- You can now restart your web service in order to see the change take effect
Hosting
You must make the request to Ikoula support so that we are studying the possibility of increasing the limit of characters in fields on your hosting.
To do this please contact us at the following address : support@ikoula.com
Do not forget to provide us with as much detail as possible (delivery number, type of delivery, error, etc.).
Enable comment auto-refresher