Redirect WP 404 to html 时间:2017-09-08 作者:Dtheme 需要将php 404重定向到纯html以减少服务器负载。是否有任何更新?How do I skip wordpress's 404 handling and redirect all 404 errors for static files to 404.html?#adding your own handler ErrorDocument 404 /404/index.html <IfModule mod_rewrite.c> RewriteRule ^index\\.php$ - [L] RewriteCond %{REQUEST_URI} !^/(404|cgi-bin|wp-admin|wp-content|wp-includes) RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule . /index.php [L] </IfModule> 1 个回复 SO网友:Jeff Mattson 看起来您有:ErrorDocument 404 http://domain.com/custom_404.php 您只需创建名为custom_404.php 在您的子主题或域的根中。儿童主题将是:http://domain.com/wp-content/themes/child_theme/custom_404.php 结束 文章导航