[wp-trac] [WordPress Trac] #21951: Twenty Twelve: add post_type_archive_title to archive.php

WordPress Trac wp-trac at lists.automattic.com
Mon Sep 24 17:26:03 UTC 2012


#21951: Twenty Twelve: add post_type_archive_title to archive.php
-----------------------------------+----------------------
 Reporter:  thomask                |       Owner:
     Type:  enhancement            |      Status:  closed
 Priority:  normal                 |   Milestone:
Component:  Bundled Theme          |     Version:
 Severity:  normal                 |  Resolution:  wontfix
 Keywords:  has-patch 2nd-opinion  |
-----------------------------------+----------------------
Changes (by thomask):

 * keywords:  has-patch => has-patch 2nd-opinion


Comment:

 Sorry, could we please put this to some wider discussion and not just
 close/wontfix it without knowing more opinions?! (I am not reopening it
 now as you are the boss, so it is up to you, but i strongly disagree)

 1. problem of the current sollution, is that we '''have to''' create new
 archive file for every custom post type, even when we are perfectly OK
 with the other archive.php content, or we need to copy current archive.php
 and change it. There is even no easy way, how we can filter it. So if you
 realy want to stay with the current sollution, *please* at least do a
 filter for

 {{{
 else {
                                                 _e( 'Blog Archives',
 'twentytwelve' );
                                         }
 }}}

 or better - replace all printf to sprintf and then filter the result.

 2. problem of the current sollution is its complexity - programmer needs
 to know, that archive.php is used for tons of needs and each of them needs
 special title and and description.

 My sollution with the_archive_title() and the_archive_description ()
 would cut the complexity (actualy it is than the same as that sprintf() in
 above point, with advantage that it is then easy to read and code).

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/21951#comment:21>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list