[wp-trac] [WordPress Trac] #40777: Using a static 404 HTML file (dynamically generated) (and/ or .htaccess instead of favicon.ico)
WordPress Trac
noreply at wordpress.org
Tue May 16 09:37:25 UTC 2017
#40777: Using a static 404 HTML file (dynamically generated) (and/ or .htaccess
instead of favicon.ico)
----------------------------+-----------------------------
Reporter: design_dolphin | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Bootstrap/Load | Version: trunk
Severity: normal | Keywords:
Focuses: performance |
----------------------------+-----------------------------
This is a follow-up to #3426.
'''Issue:'''
favicon.ico is loaded and this causes an additional request when loading a
page, even when a website is not using this browser feature. I'm not going
to rehash the pro and con arguments in the previous ticket, and instead
will focus on continuing towards the future from here.
'''
Possible Solution:'''
If the issue is that serving 404 costs too much CPU, etc, wouldn't it be
better to serve a static 404 then? E.g. a (cached from the theme) html
page and/or through .htaccess
'''For example in .htaccess:'''
{{{
ErrorDocument 404 "<H1>Page not found</H1>"
}}}
or
{{{
ErrorDocument 404 /404.html
}}}
'''Additional performance benefit:'''
This could eliminate a broader range of performance issues with generating
a dynamic 404.
'''Source .htaccess example:'''
http://www.inmotionhosting.com/support/website/how-to/set-404-via-htaccess
--
Ticket URL: <https://core.trac.wordpress.org/ticket/40777>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list