WP_MS_Themes_List_Table

Core class used to implement displaying themes in a list table for the network admin.

Defined (1)

The class is defined in the following location(s).

/wp-admin/includes/class-wp-ms-themes-list-table.php  
  1. class WP_MS_Themes_List_Table extends WP_List_Table { 
  2.  
  3. public $site_id; 
  4. public $is_site_themes; 
  5.  
  6. private $has_items; 
  7.  
  8. /** 
  9. * Constructor. 
  10. * @since 3.1.0 
  11. * @access public 
  12. * @see WP_List_Table::__construct() for more information on default arguments. 
  13. * @global string $status 
  14. * @global int $page 
  15. * @param array $args An associative array of arguments. 
  16. */ 
  17. public function __construct( $args = array() ) { 
  18. global $status, $page; 
  19.  
  20. parent::__construct( array( 
  21. 'plural' => 'themes',  
  22. 'screen' => isset( $args['screen'] ) ? $args['screen'] : null,  
  23. ) ); 
  24.  
  25. $status = isset( $_REQUEST['theme_status'] ) ? $_REQUEST['theme_status'] : 'all'; 
  26. if ( !in_array( $status, array( 'all', 'enabled', 'disabled', 'upgrade', 'search', 'broken' ) ) ) 
  27. $status = 'all'; 
  28.  
  29. $page = $this->get_pagenum(); 
  30.  
  31. $this->is_site_themes = ( 'site-themes-network' === $this->screen->id ) ? true : false; 
  32.  
  33. if ( $this->is_site_themes ) 
  34. $this->site_id = isset( $_REQUEST['id'] ) ? intval( $_REQUEST['id'] ) : 0; 
  35.  
  36. /** 
  37. * @return array 
  38. */ 
  39. protected function get_table_classes() { 
  40. // todo: remove and add CSS for .themes 
  41. return array( 'widefat', 'plugins' ); 
  42.  
  43. /** 
  44. * @return bool 
  45. */ 
  46. public function ajax_user_can() { 
  47. if ( $this->is_site_themes ) 
  48. return current_user_can( 'manage_sites' ); 
  49. else 
  50. return current_user_can( 'manage_network_themes' ); 
  51.  
  52. /** 
  53. * @global string $status 
  54. * @global array $totals 
  55. * @global int $page 
  56. * @global string $orderby 
  57. * @global string $order 
  58. * @global string $s 
  59. */ 
  60. public function prepare_items() { 
  61. global $status, $totals, $page, $orderby, $order, $s; 
  62.  
  63. wp_reset_vars( array( 'orderby', 'order', 's' ) ); 
  64.  
  65. $themes = array( 
  66. /** 
  67. * Filters the full array of WP_Theme objects to list in the Multisite 
  68. * themes list table. 
  69. * @since 3.1.0 
  70. * @param array $all An array of WP_Theme objects to display in the list table. 
  71. */ 
  72. 'all' => apply_filters( 'all_themes', wp_get_themes() ),  
  73. 'search' => array(),  
  74. 'enabled' => array(),  
  75. 'disabled' => array(),  
  76. 'upgrade' => array(),  
  77. 'broken' => $this->is_site_themes ? array() : wp_get_themes( array( 'errors' => true ) ),  
  78. ); 
  79.  
  80. if ( $this->is_site_themes ) { 
  81. $themes_per_page = $this->get_items_per_page( 'site_themes_network_per_page' ); 
  82. $allowed_where = 'site'; 
  83. } else { 
  84. $themes_per_page = $this->get_items_per_page( 'themes_network_per_page' ); 
  85. $allowed_where = 'network'; 
  86.  
  87. $maybe_update = current_user_can( 'update_themes' ) && ! $this->is_site_themes && $current = get_site_transient( 'update_themes' ); 
  88.  
  89. foreach ( (array) $themes['all'] as $key => $theme ) { 
  90. if ( $this->is_site_themes && $theme->is_allowed( 'network' ) ) { 
  91. unset( $themes['all'][ $key ] ); 
  92. continue; 
  93.  
  94. if ( $maybe_update && isset( $current->response[ $key ] ) ) { 
  95. $themes['all'][ $key ]->update = true; 
  96. $themes['upgrade'][ $key ] = $themes['all'][ $key ]; 
  97.  
  98. $filter = $theme->is_allowed( $allowed_where, $this->site_id ) ? 'enabled' : 'disabled'; 
  99. $themes[ $filter ][ $key ] = $themes['all'][ $key ]; 
  100.  
  101. if ( $s ) { 
  102. $status = 'search'; 
  103. $themes['search'] = array_filter( array_merge( $themes['all'], $themes['broken'] ), array( $this, '_search_callback' ) ); 
  104.  
  105. $totals = array(); 
  106. foreach ( $themes as $type => $list ) 
  107. $totals[ $type ] = count( $list ); 
  108.  
  109. if ( empty( $themes[ $status ] ) && !in_array( $status, array( 'all', 'search' ) ) ) 
  110. $status = 'all'; 
  111.  
  112. $this->items = $themes[ $status ]; 
  113. WP_Theme::sort_by_name( $this->items ); 
  114.  
  115. $this->has_items = ! empty( $themes['all'] ); 
  116. $total_this_page = $totals[ $status ]; 
  117.  
  118. wp_localize_script( 'updates', '_wpUpdatesItemCounts', array( 
  119. 'themes' => $totals,  
  120. 'totals' => wp_get_update_data(),  
  121. ) ); 
  122.  
  123. if ( $orderby ) { 
  124. $orderby = ucfirst( $orderby ); 
  125. $order = strtoupper( $order ); 
  126.  
  127. if ( $orderby === 'Name' ) { 
  128. if ( 'ASC' === $order ) { 
  129. $this->items = array_reverse( $this->items ); 
  130. } else { 
  131. uasort( $this->items, array( $this, '_order_callback' ) ); 
  132.  
  133. $start = ( $page - 1 ) * $themes_per_page; 
  134.  
  135. if ( $total_this_page > $themes_per_page ) 
  136. $this->items = array_slice( $this->items, $start, $themes_per_page, true ); 
  137.  
  138. $this->set_pagination_args( array( 
  139. 'total_items' => $total_this_page,  
  140. 'per_page' => $themes_per_page,  
  141. ) ); 
  142.  
  143. /** 
  144. * @staticvar string $term 
  145. * @param WP_Theme $theme 
  146. * @return bool 
  147. */ 
  148. public function _search_callback( $theme ) { 
  149. static $term = null; 
  150. if ( is_null( $term ) ) 
  151. $term = wp_unslash( $_REQUEST['s'] ); 
  152.  
  153. foreach ( array( 'Name', 'Description', 'Author', 'Author', 'AuthorURI' ) as $field ) { 
  154. // Don't mark up; Do translate. 
  155. if ( false !== stripos( $theme->display( $field, false, true ), $term ) ) 
  156. return true; 
  157.  
  158. if ( false !== stripos( $theme->get_stylesheet(), $term ) ) 
  159. return true; 
  160.  
  161. if ( false !== stripos( $theme->get_template(), $term ) ) 
  162. return true; 
  163.  
  164. return false; 
  165.  
  166. // Not used by any core columns. 
  167. /** 
  168. * @global string $orderby 
  169. * @global string $order 
  170. * @param array $theme_a 
  171. * @param array $theme_b 
  172. * @return int 
  173. */ 
  174. public function _order_callback( $theme_a, $theme_b ) { 
  175. global $orderby, $order; 
  176.  
  177. $a = $theme_a[ $orderby ]; 
  178. $b = $theme_b[ $orderby ]; 
  179.  
  180. if ( $a == $b ) 
  181. return 0; 
  182.  
  183. if ( 'DESC' === $order ) 
  184. return ( $a < $b ) ? 1 : -1; 
  185. else 
  186. return ( $a < $b ) ? -1 : 1; 
  187.  
  188. /** 
  189. * @access public 
  190. */ 
  191. public function no_items() { 
  192. if ( $this->has_items ) { 
  193. _e( 'No themes found.' ); 
  194. } else { 
  195. _e( 'You do not appear to have any themes available at this time.' ); 
  196.  
  197. /** 
  198. * @return array 
  199. */ 
  200. public function get_columns() { 
  201. return array( 
  202. 'cb' => '<input type="checkbox" />',  
  203. 'name' => __( 'Theme' ),  
  204. 'description' => __( 'Description' ),  
  205. ); 
  206.  
  207. /** 
  208. * @return array 
  209. */ 
  210. protected function get_sortable_columns() { 
  211. return array( 
  212. 'name' => 'name',  
  213. ); 
  214.  
  215. /** 
  216. * Gets the name of the primary column. 
  217. * @since 4.3.0 
  218. * @access protected 
  219. * @return string Unalterable name of the primary column name, in this case, 'name'. 
  220. */ 
  221. protected function get_primary_column_name() { 
  222. return 'name'; 
  223.  
  224. /** 
  225. * @global array $totals 
  226. * @global string $status 
  227. * @return array 
  228. */ 
  229. protected function get_views() { 
  230. global $totals, $status; 
  231.  
  232. $status_links = array(); 
  233. foreach ( $totals as $type => $count ) { 
  234. if ( !$count ) 
  235. continue; 
  236.  
  237. switch ( $type ) { 
  238. case 'all': 
  239. $text = _nx( 'All <span class="count">(%s)</span>', 'All <span class="count">(%s)</span>', $count, 'themes' ); 
  240. break; 
  241. case 'enabled': 
  242. $text = _n( 'Enabled <span class="count">(%s)</span>', 'Enabled <span class="count">(%s)</span>', $count ); 
  243. break; 
  244. case 'disabled': 
  245. $text = _n( 'Disabled <span class="count">(%s)</span>', 'Disabled <span class="count">(%s)</span>', $count ); 
  246. break; 
  247. case 'upgrade': 
  248. $text = _n( 'Update Available <span class="count">(%s)</span>', 'Update Available <span class="count">(%s)</span>', $count ); 
  249. break; 
  250. case 'broken' : 
  251. $text = _n( 'Broken <span class="count">(%s)</span>', 'Broken <span class="count">(%s)</span>', $count ); 
  252. break; 
  253.  
  254. if ( $this->is_site_themes ) 
  255. $url = 'site-themes.php?id=' . $this->site_id; 
  256. else 
  257. $url = 'themes.php'; 
  258.  
  259. if ( 'search' != $type ) { 
  260. $status_links[$type] = sprintf( "<a href='%s' %s>%s</a>",  
  261. esc_url( add_query_arg('theme_status', $type, $url) ),  
  262. ( $type === $status ) ? ' class="current"' : '',  
  263. sprintf( $text, number_format_i18n( $count ) ) 
  264. ); 
  265.  
  266. return $status_links; 
  267.  
  268. /** 
  269. * @global string $status 
  270. * @return array 
  271. */ 
  272. protected function get_bulk_actions() { 
  273. global $status; 
  274.  
  275. $actions = array(); 
  276. if ( 'enabled' != $status ) 
  277. $actions['enable-selected'] = $this->is_site_themes ? __( 'Enable' ) : __( 'Network Enable' ); 
  278. if ( 'disabled' != $status ) 
  279. $actions['disable-selected'] = $this->is_site_themes ? __( 'Disable' ) : __( 'Network Disable' ); 
  280. if ( ! $this->is_site_themes ) { 
  281. if ( current_user_can( 'update_themes' ) ) 
  282. $actions['update-selected'] = __( 'Update' ); 
  283. if ( current_user_can( 'delete_themes' ) ) 
  284. $actions['delete-selected'] = __( 'Delete' ); 
  285. return $actions; 
  286.  
  287. /** 
  288. * @access public 
  289. */ 
  290. public function display_rows() { 
  291. foreach ( $this->items as $theme ) 
  292. $this->single_row( $theme ); 
  293.  
  294. /** 
  295. * Handles the checkbox column output. 
  296. * @since 4.3.0 
  297. * @access public 
  298. * @param WP_Theme $theme The current WP_Theme object. 
  299. */ 
  300. public function column_cb( $theme ) { 
  301. $checkbox_id = 'checkbox_' . md5( $theme->get('Name') ); 
  302. ?> 
  303. <input type="checkbox" name="checked[]" value="<?php echo esc_attr( $theme->get_stylesheet() ) ?>" id="<?php echo $checkbox_id ?>" /> 
  304. <label class="screen-reader-text" for="<?php echo $checkbox_id ?>" ><?php _e( 'Select' ) ?> <?php echo $theme->display( 'Name' ) ?></label> 
  305. <?php 
  306.  
  307. /** 
  308. * Handles the name column output. 
  309. * @since 4.3.0 
  310. * @access public 
  311. * @global string $status 
  312. * @global int $page 
  313. * @global string $s 
  314. * @param WP_Theme $theme The current WP_Theme object. 
  315. */ 
  316. public function column_name( $theme ) { 
  317. global $status, $page, $s; 
  318.  
  319. $context = $status; 
  320.  
  321. if ( $this->is_site_themes ) { 
  322. $url = "site-themes.php?id={$this->site_id}&"; 
  323. $allowed = $theme->is_allowed( 'site', $this->site_id ); 
  324. } else { 
  325. $url = 'themes.php?'; 
  326. $allowed = $theme->is_allowed( 'network' ); 
  327.  
  328. // Pre-order. 
  329. $actions = array( 
  330. 'enable' => '',  
  331. 'disable' => '',  
  332. 'edit' => '',  
  333. 'delete' => '' 
  334. ); 
  335.  
  336. $stylesheet = $theme->get_stylesheet(); 
  337. $theme_key = urlencode( $stylesheet ); 
  338.  
  339. if ( ! $allowed ) { 
  340. if ( ! $theme->errors() ) { 
  341. $url = add_query_arg( array( 
  342. 'action' => 'enable',  
  343. 'theme' => $theme_key,  
  344. 'paged' => $page,  
  345. 's' => $s,  
  346. ), $url ); 
  347.  
  348. if ( $this->is_site_themes ) { 
  349. /** translators: %s: theme name */ 
  350. $aria_label = sprintf( __( 'Enable %s' ), $theme->display( 'Name' ) ); 
  351. } else { 
  352. /** translators: %s: theme name */ 
  353. $aria_label = sprintf( __( 'Network Enable %s' ), $theme->display( 'Name' ) ); 
  354.  
  355. $actions['enable'] = sprintf( '<a href="%s" class="edit" aria-label="%s">%s</a>',  
  356. esc_url( wp_nonce_url( $url, 'enable-theme_' . $stylesheet ) ),  
  357. esc_attr( $aria_label ),  
  358. ( $this->is_site_themes ? __( 'Enable' ) : __( 'Network Enable' ) ) 
  359. ); 
  360. } else { 
  361. $url = add_query_arg( array( 
  362. 'action' => 'disable',  
  363. 'theme' => $theme_key,  
  364. 'paged' => $page,  
  365. 's' => $s,  
  366. ), $url ); 
  367.  
  368. if ( $this->is_site_themes ) { 
  369. /** translators: %s: theme name */ 
  370. $aria_label = sprintf( __( 'Disable %s' ), $theme->display( 'Name' ) ); 
  371. } else { 
  372. /** translators: %s: theme name */ 
  373. $aria_label = sprintf( __( 'Network Disable %s' ), $theme->display( 'Name' ) ); 
  374.  
  375. $actions['disable'] = sprintf( '<a href="%s" aria-label="%s">%s</a>',  
  376. esc_url( wp_nonce_url( $url, 'disable-theme_' . $stylesheet ) ),  
  377. esc_attr( $aria_label ),  
  378. ( $this->is_site_themes ? __( 'Disable' ) : __( 'Network Disable' ) ) 
  379. ); 
  380.  
  381. if ( current_user_can('edit_themes') ) { 
  382. $url = add_query_arg( array( 
  383. 'theme' => $theme_key,  
  384. ), 'theme-editor.php' ); 
  385.  
  386. /** translators: %s: theme name */ 
  387. $aria_label = sprintf( __( 'Open %s in the Theme Editor' ), $theme->display( 'Name' ) ); 
  388.  
  389. $actions['edit'] = sprintf( '<a href="%s" class="edit" aria-label="%s">%s</a>',  
  390. esc_url( $url ),  
  391. esc_attr( $aria_label ),  
  392. __( 'Edit' ) 
  393. ); 
  394.  
  395. if ( ! $allowed && current_user_can( 'delete_themes' ) && ! $this->is_site_themes && $stylesheet != get_option( 'stylesheet' ) && $stylesheet != get_option( 'template' ) ) { 
  396. $url = add_query_arg( array( 
  397. 'action' => 'delete-selected',  
  398. 'checked[]' => $theme_key,  
  399. 'theme_status' => $context,  
  400. 'paged' => $page,  
  401. 's' => $s,  
  402. ), 'themes.php' ); 
  403.  
  404. /** translators: %s: theme name */ 
  405. $aria_label = sprintf( _x( 'Delete %s', 'theme' ), $theme->display( 'Name' ) ); 
  406.  
  407. $actions['delete'] = sprintf( '<a href="%s" class="delete" aria-label="%s">%s</a>',  
  408. esc_url( wp_nonce_url( $url, 'bulk-themes' ) ),  
  409. esc_attr( $aria_label ),  
  410. __( 'Delete' ) 
  411. ); 
  412. /** 
  413. * Filters the action links displayed for each theme in the Multisite 
  414. * themes list table. 
  415. * The action links displayed are determined by the theme's status, and 
  416. * which Multisite themes list table is being displayed - the Network 
  417. * themes list table (themes.php), which displays all installed themes,  
  418. * or the Site themes list table (site-themes.php), which displays the 
  419. * non-network enabled themes when editing a site in the Network admin. 
  420. * The default action links for the Network themes list table include 
  421. * 'Network Enable', 'Network Disable', 'Edit', and 'Delete'. 
  422. * The default action links for the Site themes list table include 
  423. * 'Enable', 'Disable', and 'Edit'. 
  424. * @since 2.8.0 
  425. * @param array $actions An array of action links. 
  426. * @param WP_Theme $theme The current WP_Theme object. 
  427. * @param string $context Status of the theme. 
  428. */ 
  429. $actions = apply_filters( 'theme_action_links', array_filter( $actions ), $theme, $context ); 
  430.  
  431. /** 
  432. * Filters the action links of a specific theme in the Multisite themes 
  433. * list table. 
  434. * The dynamic portion of the hook name, `$stylesheet`, refers to the 
  435. * directory name of the theme, which in most cases is synonymous 
  436. * with the template name. 
  437. * @since 3.1.0 
  438. * @param array $actions An array of action links. 
  439. * @param WP_Theme $theme The current WP_Theme object. 
  440. * @param string $context Status of the theme. 
  441. */ 
  442. $actions = apply_filters( "theme_action_links_{$stylesheet}", $actions, $theme, $context ); 
  443.  
  444. echo $this->row_actions( $actions, true ); 
  445.  
  446. /** 
  447. * Handles the description column output. 
  448. * @since 4.3.0 
  449. * @access public 
  450. * @global string $status 
  451. * @global array $totals 
  452. * @param WP_Theme $theme The current WP_Theme object. 
  453. */ 
  454. public function column_description( $theme ) { 
  455. global $status, $totals; 
  456. if ( $theme->errors() ) { 
  457. $pre = $status === 'broken' ? __( 'Broken Theme:' ) . ' ' : ''; 
  458. echo '<p><strong class="error-message">' . $pre . $theme->errors()->get_error_message() . '</strong></p>'; 
  459.  
  460. if ( $this->is_site_themes ) { 
  461. $allowed = $theme->is_allowed( 'site', $this->site_id ); 
  462. } else { 
  463. $allowed = $theme->is_allowed( 'network' ); 
  464.  
  465. $class = ! $allowed ? 'inactive' : 'active'; 
  466. if ( ! empty( $totals['upgrade'] ) && ! empty( $theme->update ) ) 
  467. $class .= ' update'; 
  468.  
  469. echo "<div class='theme-description'><p>" . $theme->display( 'Description' ) . "</p></div> 
  470. <div class='$class second theme-version-author-uri'>"; 
  471.  
  472. $stylesheet = $theme->get_stylesheet(); 
  473. $theme_meta = array(); 
  474.  
  475. if ( $theme->get('Version') ) { 
  476. $theme_meta[] = sprintf( __( 'Version %s' ), $theme->display('Version') ); 
  477. $theme_meta[] = sprintf( __( 'By %s' ), $theme->display('Author') ); 
  478.  
  479. if ( $theme->get('ThemeURI') ) { 
  480. /** translators: %s: theme name */ 
  481. $aria_label = sprintf( __( 'Visit %s homepage' ), $theme->display( 'Name' ) ); 
  482.  
  483. $theme_meta[] = sprintf( '<a href="%s" aria-label="%s">%s</a>',  
  484. $theme->display( 'ThemeURI' ),  
  485. esc_attr( $aria_label ),  
  486. __( 'Visit Theme Site' ) 
  487. ); 
  488. /** 
  489. * Filters the array of row meta for each theme in the Multisite themes 
  490. * list table. 
  491. * @since 3.1.0 
  492. * @param array $theme_meta An array of the theme's metadata,  
  493. * including the version, author, and 
  494. * theme URI. 
  495. * @param string $stylesheet Directory name of the theme. 
  496. * @param WP_Theme $theme WP_Theme object. 
  497. * @param string $status Status of the theme. 
  498. */ 
  499. $theme_meta = apply_filters( 'theme_row_meta', $theme_meta, $stylesheet, $theme, $status ); 
  500. echo implode( ' | ', $theme_meta ); 
  501.  
  502. echo '</div>'; 
  503.  
  504. /** 
  505. * Handles default column output. 
  506. * @since 4.3.0 
  507. * @access public 
  508. * @param WP_Theme $theme The current WP_Theme object. 
  509. * @param string $column_name The current column name. 
  510. */ 
  511. public function column_default( $theme, $column_name ) { 
  512. $stylesheet = $theme->get_stylesheet(); 
  513.  
  514. /** 
  515. * Fires inside each custom column of the Multisite themes list table. 
  516. * @since 3.1.0 
  517. * @param string $column_name Name of the column. 
  518. * @param string $stylesheet Directory name of the theme. 
  519. * @param WP_Theme $theme Current WP_Theme object. 
  520. */ 
  521. do_action( 'manage_themes_custom_column', $column_name, $stylesheet, $theme ); 
  522.  
  523. /** 
  524. * Handles the output for a single table row. 
  525. * @since 4.3.0 
  526. * @access public 
  527. * @param WP_Theme $item The current WP_Theme object. 
  528. */ 
  529. public function single_row_columns( $item ) { 
  530. list( $columns, $hidden, $sortable, $primary ) = $this->get_column_info(); 
  531.  
  532. foreach ( $columns as $column_name => $column_display_name ) { 
  533. $extra_classes = ''; 
  534. if ( in_array( $column_name, $hidden ) ) { 
  535. $extra_classes .= ' hidden'; 
  536.  
  537. switch ( $column_name ) { 
  538. case 'cb': 
  539. echo '<th scope="row" class="check-column">'; 
  540.  
  541. $this->column_cb( $item ); 
  542.  
  543. echo '</th>'; 
  544. break; 
  545.  
  546. case 'name': 
  547. echo "<td class='theme-title column-primary{$extra_classes}'><strong>" . $item->display('Name') . "</strong>"; 
  548.  
  549. $this->column_name( $item ); 
  550.  
  551. echo "</td>"; 
  552. break; 
  553.  
  554. case 'description': 
  555. echo "<td class='column-description desc{$extra_classes}'>"; 
  556.  
  557. $this->column_description( $item ); 
  558.  
  559. echo '</td>'; 
  560. break; 
  561.  
  562. default: 
  563. echo "<td class='$column_name column-$column_name{$extra_classes}'>"; 
  564.  
  565. $this->column_default( $item, $column_name ); 
  566.  
  567. echo "</td>"; 
  568. break; 
  569.  
  570. /** 
  571. * @global string $status 
  572. * @global array $totals 
  573. * @param WP_Theme $theme 
  574. */ 
  575. public function single_row( $theme ) { 
  576. global $status, $totals; 
  577.  
  578. if ( $this->is_site_themes ) { 
  579. $allowed = $theme->is_allowed( 'site', $this->site_id ); 
  580. } else { 
  581. $allowed = $theme->is_allowed( 'network' ); 
  582.  
  583. $stylesheet = $theme->get_stylesheet(); 
  584.  
  585. $class = ! $allowed ? 'inactive' : 'active'; 
  586. if ( ! empty( $totals['upgrade'] ) && ! empty( $theme->update ) ) { 
  587. $class .= ' update'; 
  588.  
  589. printf( '<tr class="%s" data-slug="%s">',  
  590. esc_attr( $class ),  
  591. esc_attr( $stylesheet ) 
  592. ); 
  593.  
  594. $this->single_row_columns( $theme ); 
  595.  
  596. echo "</tr>"; 
  597.  
  598. if ( $this->is_site_themes ) 
  599. remove_action( "after_theme_row_$stylesheet", 'wp_theme_update_row' ); 
  600.  
  601. /** 
  602. * Fires after each row in the Multisite themes list table. 
  603. * @since 3.1.0 
  604. * @param string $stylesheet Directory name of the theme. 
  605. * @param WP_Theme $theme Current WP_Theme object. 
  606. * @param string $status Status of the theme. 
  607. */ 
  608. do_action( 'after_theme_row', $stylesheet, $theme, $status ); 
  609.  
  610. /** 
  611. * Fires after each specific row in the Multisite themes list table. 
  612. * The dynamic portion of the hook name, `$stylesheet`, refers to the 
  613. * directory name of the theme, most often synonymous with the template 
  614. * name of the theme. 
  615. * @since 3.5.0 
  616. * @param string $stylesheet Directory name of the theme. 
  617. * @param WP_Theme $theme Current WP_Theme object. 
  618. * @param string $status Status of the theme. 
  619. */ 
  620. do_action( "after_theme_row_{$stylesheet}", $stylesheet, $theme, $status );