[wp-trac] [WordPress Trac] #38738: Remove front page restrictions from new custom header functions
WordPress Trac
noreply at wordpress.org
Sat Nov 12 01:08:34 UTC 2016
#38738: Remove front page restrictions from new custom header functions
---------------------------+--------------------
Reporter: peterwilsoncc | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 4.7
Component: Themes | Version: trunk
Severity: normal | Resolution:
Keywords: has-patch | Focuses:
---------------------------+--------------------
Comment (by peterwilsoncc):
While a callback is clean, a filter seems more WordPressy.
{{{#!php
function is_header_video_active() {
return apply_filters( 'is_header_video_active', '__return_true' );
}
}}}
Should additional arguments be added in a future release, the logic is
built in to WP hooks already.
I'll put together an alternative once I'm across the existing patch.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/38738#comment:11>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list