douxiji8707 2017-01-10 16:34
浏览 102

我已经更改了我的服务器上相关或不相关的每个PHP.ini,* .ini,以便将post_max_size设置为8000M,但它无法正常工作

I have changed every last PHP.ini, *.ini related or unrelated on my server for setting post_max_size to 8000M but its not working.But atleast 50M will do my work.I am stuck here. restarted server after changing every php.ini
httpd - k restart
even stopped server and start again.

but i cant see a small change in PHP.info

tried various tricks like
1) php_ini
2) .htaccess
3) .user.ini
but not getting desired result .Please help

I have dedicated server.With WHM and root access but still nothing working CentOS release 6.8 (Final)

All the suggested answers make change in HTACESS or php.ini while i already changed on it. more than any time.

  • 写回答

1条回答 默认 最新

  • dphs48626 2017-01-10 18:23
    关注

    First create a phpinfo.php file within your web directory (ideally in the same folder where the scripts you are testing are saved) containing:

    <?php
    phpinfo();
    

    Then access this file using a browser. Right close to the top there is a line saying:

    Loaded Configuration File /etc/php/some/path/php.ini

    Edit the loaded php.ini file as follows:

    ; Maximum allowed size for uploaded files.
    upload_max_filesize = 50M
    
    ; Must be greater than or equal to upload_max_filesize
    post_max_size = 50M
    

    Your question mentions only post_max_size, but if your form accepts files you need to change upload_max_filesize too.

    After that you need to restart the web sever (apache?). If you are using php-fpm then you need to restart that process. I don't know about centOS, but for ubuntu commands can be:

    sudo service apache2 restart
    sudo service php-fpm restart
    

    Reload the phpinfo file in your browser and check if both values have been updated.

    评论

报告相同问题?

悬赏问题

  • ¥15 孟德尔随机化结果不一致
  • ¥15 apm2.8飞控罗盘bad health,加速度计校准失败
  • ¥15 求解O-S方程的特征值问题给出边界层布拉休斯平行流的中性曲线
  • ¥15 谁有desed数据集呀
  • ¥20 手写数字识别运行c仿真时,程序报错错误代码sim211-100
  • ¥15 关于#hadoop#的问题
  • ¥15 (标签-Python|关键词-socket)
  • ¥15 keil里为什么main.c定义的函数在it.c调用不了
  • ¥50 切换TabTip键盘的输入法
  • ¥15 可否在不同线程中调用封装数据库操作的类