新框架容易爆出的错误
Not Found
The requested URL /admin/addshow was not found on this server.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

这种情况有可能是 新配置的框架public下文件缺少编译代码

#<IfModule mod_rewrite.c>
# Options +FollowSymlinks -Multiviews
# RewriteEngine On
#
# RewriteCond %{REQUEST_FILENAME} !-d
# RewriteCond %{REQUEST_FILENAME} !-f
# RewriteRule ^(.*)$ index.php/$1 [QSA,PT,L]
#</IfModule>
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L]
</IfModule>
这段代码复制进去就解决错误了
本文介绍了一种常见的404 Not Found错误,并提供了一个具体的解决方案。通过修改.htaccess文件中的重写规则,可以有效地解决因新框架配置不当导致的问题。
8032

被折叠的 条评论
为什么被折叠?



