在我更改了php.ini
最大文件上传大小和最大帖子大小后,重新启动 Apache 会显示标题中的错误。为什么?如何解决?
# vi /etc/php.ini
# service httpd restart
# service httpd start
Starting httpd: Syntax error on line 304 of /etc/httpd/conf/httpd.conf:
Invalid command 'remove', perhaps misspelled or defined by a module not included in the server configuration
第 304 行如下:
<Directory />
Options Includes Indexes FollowSymLinks MultiViews
remove word Indexes
Options Includes FollowSymlinks MultiViews
AllowOverride None
</Directory>
答案1
删除该代码片段中的第 3 行和第 4 行。您的配置应如下所示
<Directory />
Options Includes Indexes FollowSymLinks MultiViews
AllowOverride None
</Directory>