mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 01:27:36 +01:00
Title filtering from jhodgdon. fixes #3926
git-svn-id: http://svn.automattic.com/wordpress/trunk@5013 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
3802dee776
commit
774bdc405b
@ -580,13 +580,14 @@ class Walker_Category extends Walker {
|
||||
extract($args);
|
||||
|
||||
$cat_name = attribute_escape( $category->cat_name);
|
||||
$cat_name = apply_filters( 'list_cats', $cat_name, $category );
|
||||
$link = '<a href="' . get_category_link( $category->cat_ID ) . '" ';
|
||||
if ( $use_desc_for_title == 0 || empty($category->category_description) )
|
||||
$link .= 'title="' . sprintf(__( 'View all posts filed under %s' ), $cat_name) . '"';
|
||||
else
|
||||
$link .= 'title="' . attribute_escape( apply_filters( 'category_description', $category->category_description, $category )) . '"';
|
||||
$link .= '>';
|
||||
$link .= apply_filters( 'list_cats', $category->cat_name, $category ).'</a>';
|
||||
$link .= $cat_name . '</a>';
|
||||
|
||||
if ( (! empty($feed_image)) || (! empty($feed)) ) {
|
||||
$link .= ' ';
|
||||
|
@ -582,12 +582,16 @@ function get_calendar($initial = true) {
|
||||
);
|
||||
if ( $ak_post_titles ) {
|
||||
foreach ( $ak_post_titles as $ak_post_title ) {
|
||||
|
||||
$post_title = apply_filters( "the_title", $ak_post_title->post_title );
|
||||
$post_title = str_replace('"', '"', wptexturize( $post_title ));
|
||||
|
||||
if ( empty($ak_titles_for_day['day_'.$ak_post_title->dom]) )
|
||||
$ak_titles_for_day['day_'.$ak_post_title->dom] = '';
|
||||
if ( empty($ak_titles_for_day["$ak_post_title->dom"]) ) // first one
|
||||
$ak_titles_for_day["$ak_post_title->dom"] = str_replace('"', '"', wptexturize($ak_post_title->post_title));
|
||||
$ak_titles_for_day["$ak_post_title->dom"] = $post_title;
|
||||
else
|
||||
$ak_titles_for_day["$ak_post_title->dom"] .= $ak_title_separator . str_replace('"', '"', wptexturize($ak_post_title->post_title));
|
||||
$ak_titles_for_day["$ak_post_title->dom"] .= $ak_title_separator . $post_title;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user