[wp-trac] [WordPress Trac] #23929: Ability to remove post format UI
WordPress Trac
noreply at wordpress.org
Wed Apr 3 19:50:51 UTC 2013
#23929: Ability to remove post format UI
--------------------------+------------------------------
Reporter: johnbillion | Owner:
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Post Formats | Version: trunk
Severity: normal | Resolution:
Keywords: has-patch |
--------------------------+------------------------------
Changes (by johnbillion):
* keywords: => has-patch
Comment:
Patch which adds a new `show_post_format_ui` filter (boolean) for
disabling the post format UI on the post editing screen.
Example usage:
{{{
add_filter( 'show_post_format_ui', '__return_false' );
}}}
or
{{{
add_filter( 'show_post_format_ui', function( $show, $post_type ) {
if ( 'my_post_type' == $post_type )
return false;
return $show;
}, 10, 2 );
}}}
I toyed with the idea of removing the post format icons that are shown
next to posts on the post listing screen too, but decided they should not
be affected by this filter. They're easy enough to hide with CSS anyway.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/23929#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list