#4077 closed defect (bug) (fixed)
Need ability to add namespace to admin screens HTML header
Reported by: | jhodgdon | Owned by: | rob1n |
---|---|---|---|
Milestone: | 2.2 | Priority: | normal |
Severity: | minor | Version: | 2.1.2 |
Component: | Administration | Keywords: | has-patch 2nd-opinion |
Focuses: | Cc: |
Description
A certain Google Maps API requires that an additional xmlns attributed be added to the HTML header tag so that Internet Explorer will render it correctly (sigh). While the Theme has control over HTML headers for external viewing, wp-admin/admin-header.php has control over HTML headers for the admin screens, and there is no namespace hook. (The API is being used in both admin and external screens.)
So, I would like to request a hook be added. Patch coming shortly.
I have tested that no behavior changes in 2.1.2 and [5176] when my hook is added, and that my plugin can use the hook to add a namespace. I also verified it was a new hook name.
Attachments (2)
Change History (12)
#1
@
18 years ago
- Owner changed from anonymous to rob1n
Maybe a more descriptive filter name? Such as admin_header_ns or admin_html_ns?
Just wondering, seeing as admin_ns isn't very descriptive. Maybe even do "namespace" instead of abbreviating it to "ns."
#3
@
18 years ago
I was following the convention of the other namespace actions, such as atom_ns, rdf_ns, etc.
#4
@
18 years ago
That said, I would be happy to have the name be something else... the existing convention is not great.
There are unfortunately precidents for both inconsistencies and cryptic names... at least I have the ones in 2.1.2 now documented at http://codex.wordpress.org/Plugin_API/Action_Reference and http://codex.wordpress.org/Plugin_API/Filter_Reference -- many opportunities to make things more consistent, except for the fact that plugins are probably already using the inconsistent names.
#5
@
18 years ago
- Keywords 2nd-opinion added
I do too, but I want to get Ryan's input on this. I'm +1.
#7
@
18 years ago
I thought about this a bit more, and now I'm going for a new filter name: admin_xml_ns. *Technically* it's XML's namespace, not HTML's. And the NS could specify something that isn't HTML.
Patch to add namespace hook to admin header