equal
deleted
inserted
replaced
7 * @since 3.1.0 |
7 * @since 3.1.0 |
8 * @access private |
8 * @access private |
9 */ |
9 */ |
10 class WP_Links_List_Table extends WP_List_Table { |
10 class WP_Links_List_Table extends WP_List_Table { |
11 |
11 |
12 function __construct() { |
12 function __construct( $args = array() ) { |
13 parent::__construct( array( |
13 parent::__construct( array( |
14 'plural' => 'bookmarks', |
14 'plural' => 'bookmarks', |
|
15 'screen' => isset( $args['screen'] ) ? $args['screen'] : null, |
15 ) ); |
16 ) ); |
16 } |
17 } |
17 |
18 |
18 function ajax_user_can() { |
19 function ajax_user_can() { |
19 return current_user_can( 'manage_links' ); |
20 return current_user_can( 'manage_links' ); |
66 'hierarchical' => 1, |
67 'hierarchical' => 1, |
67 'show_count' => 0, |
68 'show_count' => 0, |
68 'orderby' => 'name', |
69 'orderby' => 'name', |
69 ); |
70 ); |
70 wp_dropdown_categories( $dropdown_options ); |
71 wp_dropdown_categories( $dropdown_options ); |
71 submit_button( __( 'Filter' ), 'secondary', false, false, array( 'id' => 'post-query-submit' ) ); |
72 submit_button( __( 'Filter' ), 'button', false, false, array( 'id' => 'post-query-submit' ) ); |
72 ?> |
73 ?> |
73 </div> |
74 </div> |
74 <?php |
75 <?php |
75 } |
76 } |
76 |
77 |
126 $style = ' style="display:none;"'; |
127 $style = ' style="display:none;"'; |
127 |
128 |
128 $attributes = $class . $style; |
129 $attributes = $class . $style; |
129 |
130 |
130 switch ( $column_name ) { |
131 switch ( $column_name ) { |
131 case 'cb': |
132 case 'cb': ?> |
132 echo '<th scope="row" class="check-column"><input type="checkbox" name="linkcheck[]" value="'. esc_attr( $link->link_id ) .'" /></th>'; |
133 <th scope="row" class="check-column"> |
|
134 <label class="screen-reader-text" for="cb-select-<?php echo $link->link_id; ?>"><?php echo sprintf( __( 'Select %s' ), $link->link_name ); ?></label> |
|
135 <input type="checkbox" name="linkcheck[]" id="cb-select-<?php echo $link->link_id; ?>" value="<?php echo esc_attr( $link->link_id ); ?>" /> |
|
136 </th> |
|
137 <?php |
133 break; |
138 break; |
134 |
139 |
135 case 'name': |
140 case 'name': |
136 echo "<td $attributes><strong><a class='row-title' href='$edit_link' title='" . esc_attr( sprintf( __( 'Edit “%s”' ), $link->link_name ) ) . "'>$link->link_name</a></strong><br />"; |
141 echo "<td $attributes><strong><a class='row-title' href='$edit_link' title='" . esc_attr( sprintf( __( 'Edit “%s”' ), $link->link_name ) ) . "'>$link->link_name</a></strong><br />"; |
137 |
142 |