<?php
/**
- * Theme Installer List Table class.
+ * List Table API: WP_Theme_Install_List_Table class
*
* @package WordPress
- * @subpackage List_Table
+ * @subpackage Administration
+ * @since 3.1.0
+ */
+
+/**
+ * Core class used to implement displaying themes to install in a list table.
+ *
* @since 3.1.0
* @access private
+ *
+ * @see WP_Thenes_List_Table
*/
class WP_Theme_Install_List_Table extends WP_Themes_List_Table {
// These are the tabs which are shown on the page,
$tabs = array();
$tabs['dashboard'] = __( 'Search' );
- if ( 'search' == $tab )
+ if ( 'search' === $tab )
$tabs['search'] = __( 'Search Results' );
$tabs['upload'] = __( 'Upload' );
$tabs['featured'] = _x( 'Featured', 'themes' );
$display_tabs = array();
foreach ( (array) $tabs as $action => $text ) {
- $class = ( $action == $tab ) ? ' class="current"' : '';
+ $class = ( $action === $tab ) ? ' class="current"' : '';
$href = self_admin_url('theme-install.php?tab=' . $action);
$display_tabs['theme-install-'.$action] = "<a href='$href'$class>$text</a>";
}
* public 'rating' => float 80
* public 'num_ratings' => int 1
* public 'homepage' => string 'http://wordpress.org/themes/magazine-basic'
- * public 'description' => string 'A basic magazine style layout with a fully customizable layout through a backend interface. Designed by <a href="http://bavotasan.com">c.bavota</a> of <a href="http://tinkerpriestmedia.com">Tinker Priest Media</a>.'
+ * public 'description' => string 'A basic magazine style layout with a fully customizable layout through a back-end interface. Designed by <a href="http://bavotasan.com">c.bavota</a> of <a href="http://tinkerpriestmedia.com">Tinker Priest Media</a>.'
* public 'download_link' => string 'http://wordpress.org/themes/download/magazine-basic.1.1.zip'
*/
public function single_row( $theme ) {
?>
<a class="screenshot install-theme-preview" href="<?php echo esc_url( $preview_url ); ?>" title="<?php echo esc_attr( $preview_title ); ?>">
- <img src="<?php echo esc_url( $theme->screenshot_url ); ?>" width="150" />
+ <img src="<?php echo esc_url( $theme->screenshot_url ); ?>" width="150" alt="" />
</a>
<h3><?php echo $name; ?></h3>
<h3 class="theme-name"><?php echo $name; ?></h3>
<span class="theme-by"><?php printf( __( 'By %s' ), $author ); ?></span>
<?php if ( isset( $theme->screenshot_url ) ): ?>
- <img class="theme-screenshot" src="<?php echo esc_url( $theme->screenshot_url ); ?>" />
+ <img class="theme-screenshot" src="<?php echo esc_url( $theme->screenshot_url ); ?>" alt="" />
<?php endif; ?>
<div class="theme-details">
<?php wp_star_rating( array( 'rating' => $theme->rating, 'type' => 'percent', 'number' => $theme->num_ratings ) ); ?>