Changeset 41685
- Timestamp:
- 10/02/2017 10:01:19 PM (7 years ago)
- Location:
- trunk/src/wp-includes/widgets
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/widgets/class-wp-widget-archives.php
r41162 r41685 62 62 * 63 63 * @since 2.8.0 64 * @since 4.9.0 Added the `$instance` parameter. 64 65 * 65 66 * @see wp_get_archives() 66 67 * 67 * @param array $args An array of Archives widget drop-down arguments. 68 * @param array $args An array of Archives widget drop-down arguments. 69 * @param array $instance Settings for the current Archives widget instance. 68 70 */ 69 71 $dropdown_args = apply_filters( 'widget_archives_dropdown_args', array( … … 71 73 'format' => 'option', 72 74 'show_post_count' => $c 73 ) );75 ), $instance ); 74 76 75 77 switch ( $dropdown_args['type'] ) { … … 103 105 * 104 106 * @since 2.8.0 107 * @since 4.9.0 Added the `$instance` parameter. 105 108 * 106 109 * @see wp_get_archives() 107 110 * 108 * @param array $args An array of Archives option arguments. 111 * @param array $args An array of Archives option arguments. 112 * @param array $instance Array of settings for the current widget. 109 113 */ 110 114 wp_get_archives( apply_filters( 'widget_archives_args', array( 111 115 'type' => 'monthly', 112 116 'show_post_count' => $c 113 ) ) );117 ), $instance ) ); 114 118 ?> 115 119 </ul> -
trunk/src/wp-includes/widgets/class-wp-widget-categories.php
r41547 r41685 77 77 * 78 78 * @since 2.8.0 79 * @since 4.9.0 Added the `$instance` parameter. 79 80 * 80 81 * @see wp_dropdown_categories() 81 82 * 82 83 * @param array $cat_args An array of Categories widget drop-down arguments. 84 * @param array $instance Array of settings for the current widget. 83 85 */ 84 wp_dropdown_categories( apply_filters( 'widget_categories_dropdown_args', $cat_args ) );86 wp_dropdown_categories( apply_filters( 'widget_categories_dropdown_args', $cat_args, $instance ) ); 85 87 86 88 echo '</form>'; … … 112 114 * 113 115 * @since 2.8.0 116 * @since 4.9.0 Added the `$instance` parameter. 114 117 * 115 118 * @param array $cat_args An array of Categories widget options. 119 * @param array $instance Array of settings for the current widget. 116 120 */ 117 wp_list_categories( apply_filters( 'widget_categories_args', $cat_args ) );121 wp_list_categories( apply_filters( 'widget_categories_args', $cat_args, $instance ) ); 118 122 ?> 119 123 </ul> -
trunk/src/wp-includes/widgets/class-wp-widget-links.php
r41162 r41685 71 71 * 72 72 * @since 2.6.0 73 * @since 4.4.0 The `$instance` parameter was added.73 * @since 4.4.0 Added the `$instance` parameter. 74 74 * 75 75 * @see wp_list_bookmarks() -
trunk/src/wp-includes/widgets/class-wp-widget-meta.php
r41162 r41685 61 61 * 62 62 * @since 3.6.0 63 * @since 4.9.0 Added the `$instance` parameter. 63 64 * 64 65 * @param string $title_text Default title text for the WordPress.org link. 66 * @param array $instance Array of settings for the current widget. 65 67 */ 66 68 echo apply_filters( 'widget_meta_poweredby', sprintf( '<li><a href="%s" title="%s">%s</a></li>', … … 68 70 esc_attr__( 'Powered by WordPress, state-of-the-art semantic personal publishing platform.' ), 69 71 _x( 'WordPress.org', 'meta widget link text' ) 70 ) );72 ), $instance ); 71 73 72 74 wp_meta(); -
trunk/src/wp-includes/widgets/class-wp-widget-pages.php
r41162 r41685 48 48 * 49 49 * @param string $title The widget title. Default 'Pages'. 50 * @param array $instance A n array of the widget's settings.50 * @param array $instance Array of settings for the current widget. 51 51 * @param mixed $id_base The widget ID. 52 52 */ … … 63 63 * 64 64 * @since 2.8.0 65 * @since 4.9.0 Added the `$instance` parameter. 65 66 * 66 67 * @see wp_list_pages() 67 68 * 68 * @param array $args An array of arguments to retrieve the pages list. 69 * @param array $args An array of arguments to retrieve the pages list. 70 * @param array $instance Array of settings for the current widget. 69 71 */ 70 72 $out = wp_list_pages( apply_filters( 'widget_pages_args', array( … … 73 75 'sort_column' => $sortby, 74 76 'exclude' => $exclude 75 ) ) );77 ), $instance ) ); 76 78 77 79 if ( ! empty( $out ) ) { -
trunk/src/wp-includes/widgets/class-wp-widget-recent-comments.php
r41162 r41685 86 86 * 87 87 * @since 3.4.0 88 * @since 4.9.0 Added the `$instance` parameter. 88 89 * 89 90 * @see WP_Comment_Query::query() for information on accepted arguments. 90 91 * 91 92 * @param array $comment_args An array of arguments used to retrieve the recent comments. 93 * @param array $instance Array of settings for the current widget. 92 94 */ 93 95 $comments = get_comments( apply_filters( 'widget_comments_args', array( … … 95 97 'status' => 'approve', 96 98 'post_status' => 'publish' 97 ) ) );99 ), $instance ) ); 98 100 99 101 $output .= $args['before_widget']; -
trunk/src/wp-includes/widgets/class-wp-widget-recent-posts.php
r41162 r41685 60 60 * 61 61 * @since 3.4.0 62 * @since 4.9.0 Added the `$instance` parameter. 62 63 * 63 64 * @see WP_Query::get_posts() 64 65 * 65 * @param array $args An array of arguments used to retrieve the recent posts. 66 * @param array $args An array of arguments used to retrieve the recent posts. 67 * @param array $instance Array of settings for the current widget. 66 68 */ 67 69 $r = new WP_Query( apply_filters( 'widget_posts_args', array( … … 70 72 'post_status' => 'publish', 71 73 'ignore_sticky_posts' => true 72 ) ) );74 ), $instance ) ); 73 75 74 76 if ($r->have_posts()) : -
trunk/src/wp-includes/widgets/class-wp-widget-tag-cloud.php
r41162 r41685 59 59 * @since 2.8.0 60 60 * @since 3.0.0 Added taxonomy drop-down. 61 * @since 4.9.0 Added the `$instance` parameter. 61 62 * 62 63 * @see wp_tag_cloud() 63 64 * 64 * @param array $args Args used for the tag cloud widget. 65 * @param array $args Args used for the tag cloud widget. 66 * @param array $instance Array of settings for the current widget. 65 67 */ 66 68 $tag_cloud = wp_tag_cloud( apply_filters( 'widget_tag_cloud_args', array( … … 68 70 'echo' => false, 69 71 'show_count' => $show_count, 70 ) ) );72 ), $instance ) ); 71 73 72 74 if ( empty( $tag_cloud ) ) {
Note: See TracChangeset
for help on using the changeset viewer.