[wp-trac] [WordPress Trac] #27178: Filter Hook for "Default Template"

WordPress Trac noreply at wordpress.org
Fri Feb 21 21:36:03 UTC 2014


#27178: Filter Hook for "Default Template"
----------------------------+---------------------------------------
 Reporter:  johnstonphilip  |       Owner:
     Type:  enhancement     |      Status:  new
 Priority:  normal          |   Milestone:  Awaiting Review
Component:  Themes          |     Version:  3.8.1
 Severity:  normal          |  Resolution:
 Keywords:                  |     Focuses:  administration, template
----------------------------+---------------------------------------

Comment (by SergeyBiryukov):

 The string is also used in Quick Edit: [source:tags/3.8.1/src/wp-
 admin/includes/class-wp-posts-list-table.php#L935].

 You can change it via `gettext` filter:
 {{{
 function change_default_page_template_title_27178( $translated_text,
 $text, $domain ) {
         if ( is_admin() && 'Default Template' == $text ) {
                 $translated_text = 'No Sidebar';
         }

     return $translated_text;
 }
 add_filter( 'gettext', 'change_default_page_template_title_27178', 10, 3
 );
 }}}

--
Ticket URL: <https://core.trac.wordpress.org/ticket/27178#comment:3>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list