📜  htaccess if index not found 重定向 - 任何代码示例

📅  最后修改于: 2022-03-11 14:56:56.111000             🧑  作者: Mango

代码示例1
//Redirect to a URL via htaccess if index.(html|php) doesn't exist
RewriteCond %{REQUEST_FILENAME} -d
RewriteCond %{REQUEST_FILENAME}/index\.(html|php) !-f
RewriteRule ^ http://example.com/something-blew-up.html [R=302]