我试图将不存在的网页 重新定位到我的索引.php。
我用此数据创建了一个与索引.php相同的文件夹中的.htaccess 文件 。
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} -s [OR]
RewriteCond %{REQUEST_FILENAME} -l [OR]
Rewritecond %{REQUEST_FILENAME} -d
RewriteRule ^.*$ - [NC,L]
RewriteRule ^.*$ index.php [NC,L]
Im 使用 Wampserver 和 httpd.conf 设置为 apache 服务器的 httpd.conf
全部允许覆盖
But still when I try to enter a non existent webpage I get the 404 error. Any idea?
EDIT. By the way, I ve seen this post HERE And tried the stuff held there, but it didn t work for me.