Ticket #6684: widgets.php.diff
File widgets.php.diff, 3.9 KB (added by , 16 years ago) |
---|
-
E:/EclipseWorkWeb/WordPressDev/wp-includes/widgets.php
363 363 extract( $args ); 364 364 $options = get_option( 'widget_pages' ); 365 365 366 $title = empty( $options['title'] ) ? __( 'Pages' ) : $options['title'];366 $title = empty( $options['title'] ) ? __( 'Pages' ) : apply_filters('widget_title', $options['title']); 367 367 $sortby = empty( $options['sortby'] ) ? 'menu_order' : $options['sortby']; 368 368 $exclude = empty( $options['exclude'] ) ? '' : $options['exclude']; 369 369 … … 454 454 $options = get_option('widget_archives'); 455 455 $c = $options['count'] ? '1' : '0'; 456 456 $d = $options['dropdown'] ? '1' : '0'; 457 $title = empty($options['title']) ? __('Archives') : $options['title'];457 $title = empty($options['title']) ? __('Archives') : apply_filters('widget_title', $options['title']); 458 458 459 459 echo $before_widget; 460 460 echo $before_title . $title . $after_title; … … 502 502 function wp_widget_meta($args) { 503 503 extract($args); 504 504 $options = get_option('widget_meta'); 505 $title = empty($options['title']) ? __('Meta') : $options['title'];505 $title = empty($options['title']) ? __('Meta') : apply_filters('widget_title', $options['title']); 506 506 ?> 507 507 <?php echo $before_widget; ?> 508 508 <?php echo $before_title . $title . $after_title; ?> … … 536 536 function wp_widget_calendar($args) { 537 537 extract($args); 538 538 $options = get_option('widget_calendar'); 539 $title = $options['title'];539 $title = apply_filters('widget_title', $options['title']); 540 540 if ( empty($title) ) 541 541 $title = ' '; 542 542 echo $before_widget . $before_title . $title . $after_title; … … 573 573 if ( !isset($options[$number]) ) 574 574 return; 575 575 576 $title = $options[$number]['title'];576 $title = apply_filters('widget_title', $options[$number]['title']); 577 577 $text = apply_filters( 'widget_text', $options[$number]['text'] ); 578 578 ?> 579 579 <?php echo $before_widget; ?> … … 685 685 $h = $options[$number]['hierarchical'] ? '1' : '0'; 686 686 $d = $options[$number]['dropdown'] ? '1' : '0'; 687 687 688 $title = empty($options[$number]['title']) ? __('Categories') : $options[$number]['title'];688 $title = empty($options[$number]['title']) ? __('Categories') : apply_filters('widget_title', $options[$number]['title']); 689 689 690 690 echo $before_widget; 691 691 echo $before_title . $title . $after_title; … … 868 868 ob_start(); 869 869 extract($args); 870 870 $options = get_option('widget_recent_entries'); 871 $title = empty($options['title']) ? __('Recent Posts') : $options['title'];871 $title = empty($options['title']) ? __('Recent Posts') : apply_filters('widget_title', $options['title']); 872 872 if ( !$number = (int) $options['number'] ) 873 873 $number = 10; 874 874 else if ( $number < 1 ) … … 931 931 global $wpdb, $comments, $comment; 932 932 extract($args, EXTR_SKIP); 933 933 $options = get_option('widget_recent_comments'); 934 $title = empty($options['title']) ? __('Recent Comments') : $options['title'];934 $title = empty($options['title']) ? __('Recent Comments') : apply_filters('widget_title', $options['title']); 935 935 if ( !$number = (int) $options['number'] ) 936 936 $number = 5; 937 937 else if ( $number < 1 ) … … 1037 1037 $title = $desc; 1038 1038 if ( empty($title) ) 1039 1039 $title = __('Unknown Feed'); 1040 $title = apply_filters('widget_title', $title ); 1040 1041 $url = clean_url(strip_tags($url)); 1041 1042 if ( file_exists(dirname(__FILE__) . '/rss.png') ) 1042 1043 $icon = str_replace(ABSPATH, get_option('siteurl').'/', dirname(__FILE__)) . '/rss.png'; … … 1329 1330 function wp_widget_tag_cloud($args) { 1330 1331 extract($args); 1331 1332 $options = get_option('widget_tag_cloud'); 1332 $title = empty($options['title']) ? __('Tags') : $options['title'];1333 $title = empty($options['title']) ? __('Tags') : apply_filters('widget_title', $options['title']); 1333 1334 1334 1335 echo $before_widget; 1335 1336 echo $before_title . $title . $after_title;