| 272 | | if ( empty( $theme['enabled'] ) ) |
| 273 | | $actions['enable'] = '<a href="' . wp_nonce_url($url . 'action=enable&theme=' . $theme_key . '&paged=' . $page . '&s=' . $s, 'enable-theme_' . $theme_key) . '" title="' . __('Enable this theme') . '" class="edit">' . __('Enable') . '</a>'; |
| 274 | | else |
| 275 | | $actions['disable'] = '<a href="' . wp_nonce_url($url . 'action=disable&theme=' . $theme_key . '&paged=' . $page . '&s=' . $s, 'disable-theme_' . $theme_key) . '" title="' . __('Disable this theme') . '">' . __('Disable') . '</a>'; |
| 276 | | |
| 277 | | if ( current_user_can('edit_themes') ) |
| 278 | | $actions['edit'] = '<a href="theme-editor.php?theme=' . $theme['Name'] . '" title="' . __('Open this theme in the Theme Editor') . '" class="edit">' . __('Edit') . '</a>'; |
| | 274 | $theme_key = esc_html( $theme['Stylesheet'] ); |
| 280 | | $actions = apply_filters( 'theme_action_links', array_filter( $actions ), $theme_key, $theme, $context ); |
| 281 | | $actions = apply_filters( "theme_action_links_$theme_key", $actions, $theme_key, $theme, $context ); |
| | 276 | if ( empty( $theme['enabled'] ) ) |
| | 277 | $actions['enable'] = '<a href="' . wp_nonce_url($url . 'action=enable&theme=' . $theme_key . '&paged=' . $page . '&s=' . $s, 'enable-theme_' . $theme_key) . '" title="' . __('Enable this theme') . '" class="edit">' . __('Enable') . '</a>'; |
| | 278 | else |
| | 279 | $actions['disable'] = '<a href="' . wp_nonce_url($url . 'action=disable&theme=' . $theme_key . '&paged=' . $page . '&s=' . $s, 'disable-theme_' . $theme_key) . '" title="' . __('Disable this theme') . '">' . __('Disable') . '</a>'; |
| 304 | | echo "</td> |
| 305 | | <td class='desc'>"; |
| 306 | | $theme_meta = array(); |
| 307 | | if ( !empty( $theme['Version'] ) ) |
| 308 | | $theme_meta[] = sprintf( __( 'Version %s' ), $theme['Version'] ); |
| 309 | | if ( !empty( $theme['Author'] ) ) { |
| 310 | | $author = $theme['Author']; |
| 311 | | if ( !empty( $theme['Author URI'] ) ) |
| 312 | | $author = '<a href="' . $theme['Author URI'] . '" title="' . __( 'Visit author homepage' ) . '">' . $theme['Author'] . '</a>'; |
| 313 | | $theme_meta[] = sprintf( __( 'By %s' ), $author ); |
| | 298 | list( $columns, $hidden ) = $this->get_column_info(); |
| | 299 | |
| | 300 | foreach ( $columns as $column_name => $column_display_name ) { |
| | 301 | $style = ''; |
| | 302 | if ( in_array( $column_name, $hidden ) ) |
| | 303 | $style = ' style="display:none;"'; |
| | 304 | |
| | 305 | switch ( $column_name ) { |
| | 306 | case 'cb': |
| | 307 | echo "<th scope='row' class='check-column'>$checkbox</th>"; |
| | 308 | break; |
| | 309 | case 'name': |
| | 310 | echo "<td class='theme-title'$style><strong>$theme_name</strong>"; |
| | 311 | echo $this->row_actions( $actions, true ); |
| | 312 | echo "</td>"; |
| | 313 | break; |
| | 314 | case 'description': |
| | 315 | echo "<td class='column-description desc'$style> |
| | 316 | <div class='theme-description'>$description</div> |
| | 317 | <div class='$class second theme-version-author-uri'>"; |
| | 318 | |
| | 319 | $theme_meta = array(); |
| | 320 | if ( !empty( $theme['Version'] ) ) |
| | 321 | $theme_meta[] = sprintf( __( 'Version %s' ), $theme['Version'] ); |
| | 322 | if ( !empty( $theme['Author'] ) ) { |
| | 323 | $author = $theme['Author']; |
| | 324 | if ( !empty( $theme['Author URI'] ) ) |
| | 325 | $author = '<a href="' . $theme['Author URI'] . '" title="' . __( 'Visit author homepage' ) . '">' . $theme['Author'] . '</a>'; |
| | 326 | $theme_meta[] = sprintf( __( 'By %s' ), $author ); |
| | 327 | } |
| | 328 | if ( !empty( $theme['Theme URI'] ) ) |
| | 329 | $theme_meta[] = '<a href="' . $theme['Theme URI'] . '" title="' . __( 'Visit theme homepage' ) . '">' . __( 'Visit Theme Site' ) . '</a>'; |
| | 330 | |
| | 331 | $theme_meta = apply_filters( 'theme_row_meta', $theme_meta, $theme_key, $theme, $status ); |
| | 332 | echo implode( ' | ', $theme_meta ); |
| | 333 | |
| | 334 | echo "</div></td>"; |
| | 335 | break; |
| | 336 | break; |
| | 337 | default: |
| | 338 | echo "<td class='$column_name column-$column_name'$style>"; |
| | 339 | do_action( 'manage_themes_custom_column', $column_name, $theme_key, $theme ); |
| | 340 | echo "</td>"; |
| 323 | | do_action( 'after_theme_row', $theme_key, $theme, $status ); |
| 324 | | do_action( "after_theme_row_$theme_key", $theme_key, $theme, $status ); |
| 325 | | } |
| | 346 | do_action( 'after_theme_row', $theme_key, $theme, $status ); |
| | 347 | do_action( "after_theme_row_$theme_key", $theme_key, $theme, $status ); |