[wp-trac] [WordPress Trac] #25333: Can't remove theme support for certain custom header arguments
WordPress Trac
noreply at wordpress.org
Mon Sep 16 18:58:38 UTC 2013
#25333: Can't remove theme support for certain custom header arguments
--------------------------+------------------------------
Reporter: kovshenin | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Themes | Version: 3.4
Severity: normal | Resolution:
Keywords: needs-patch |
--------------------------+------------------------------
Comment (by kovshenin):
It looks like the constants are defined during the first call to
`add_theme_support` regardless of when it's called, tested with
`plugins_loaded`. Most likely because of this:
{{{
if ( defined( 'HEADER_IMAGE' ) )
$args[0]['default-image'] = HEADER_IMAGE;
elseif ( isset( $args[0]['default-image'] ) )
define( 'HEADER_IMAGE', $args[0]['default-image'] );
}}}
So the second time you call `add_theme_support` (even if you called
`remove_theme_support` before that) the values are taken from the defined
constants.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/25333#comment:3>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list