Make WordPress Core

Opened 3 weeks ago

Last modified 3 days ago

#46135 new enhancement

Add filter to disable wp_favicon_request

Reported by: shawfactor Owned by:
Milestone: Awaiting Review Priority: normal
Severity: minor Version: 5.0.3
Component: Customize Keywords: needs-patch good-first-bug reporter-feedback
Focuses: Cc:


A number of other functions in wp-includes/load.php have fikters that enable them to be disabled. However wp_favicon_request does not.

Disabling this function via a pluginn could be useful, especially in a multisite environment where you wanted to dynamicly serve a favicon in the root directory or even run a redirect.

Change History (4)

#1 @shawfactor
3 weeks ago

I am unfamiliar with the contribution process, the fix/enhancement on this is trivial but I'd love to write to and get started co tributing to core.

Last edited 3 weeks ago by shawfactor (previous) (diff)

#2 @johnbillion
3 weeks ago

  • Focuses accessibility multisite removed
  • Keywords needs-patch good-first-bug reporter-feedback added

Thanks for the ticket, @shawfactor ! Welcome to WordPress Trac.

Out of interest, is there a particular reason you want or need to disable this handling? It always helps to know the background behind requests, as it helps gauge priority and effect.

The Core Contributor Handbook is a good place to get started with contributing to WordPress: https://make.wordpress.org/core/handbook/. There are links there to some tutorials and guides that should help to get you started. Don't forget to join our Slack too: https://chat.wordpress.org/ .

Last edited 3 weeks ago by johnbillion (previous) (diff)

#3 @shawfactor
3 weeks ago

Yes as I outlined on multisite you may want different favicons per site. You can of course do this when html is returned via a meta tag but on non html requests many browsers still look for a favicon.ico at the root of the domain.

On multisite i would like to write a plugin to either generate the favicon dynamicly or redirect the request (differently depending on the site). Currently this is impossible due to the lack of a filter.

Most other functions in load.php have filters to disable them, but this function does not.

#4 @SergeyBiryukov
3 days ago

  • Component changed from General to Customize
Note: See TracTickets for help on using tickets.