[wp-trac] [WordPress Trac] #16434: Give site admin ability to upload favicon in Settings, General
WordPress Trac
wp-trac at lists.automattic.com
Fri Mar 2 15:53:00 UTC 2012
#16434: Give site admin ability to upload favicon in Settings, General
-------------------------------------------------+------------------
Reporter: jane | Owner:
Type: feature request | Status: new
Priority: normal | Milestone: 3.4
Component: Administration | Version: 3.1
Severity: normal | Resolution:
Keywords: has-patch needs-testing ux-feedback |
-------------------------------------------------+------------------
Comment (by TomAuger):
Replying to [comment:105 ocean90]:
> I just saw, that you use the basename as the value for `sitefavicon`,
can't we just use the attachment ID or better, the complete URL?
Thanks for this feedback. Here's the rationale behind using the basename
as the value: we need to accommodate both filename.png and filename.ico.
When serving up the HTML we will (eventually) have to serve up some non-IE
code referencing filename.png and then some IE-conditional code
referencing filename.ico.
If we store the attachment ID or the URL, it would have to be one or the
other (either the PNG or the ICO version of the file). Then, to serve up
the other one, we would have to reverse-engineer the filename (strip out
the TLA and substitute the correct one).
Not that that approach is all that difficult (in fact it's probably way
easier to substitute the TLA at the end rather than stripping out the
basename at the front, like I'm currently doing, but to me it doesn't feel
"right".
Now, if there were some kind of parent attachment - perhaps a "favicon"
post or something of that ilk - that both the ICO and the PNG attachment
record could reference, then I would be comfortable storing that.
For now I don't feel there's a compelling reason to refactor the way it
currently works, though I'm open to more opinions on the matter.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/16434#comment:108>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list