]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-admin/includes/class-wp-theme-install-list-table.php
WordPress 4.5-scripts
[autoinstalls/wordpress.git] / wp-admin / includes / class-wp-theme-install-list-table.php
index 427c5391489953005444823e43370dc588e50e7d..3780c89c9518962eeab707aa5457a558b633f9e0 100644 (file)
@@ -1,11 +1,19 @@
 <?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 {
 
@@ -50,7 +58,7 @@ 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' );
@@ -163,7 +171,7 @@ class WP_Theme_Install_List_Table extends WP_Themes_List_Table {
 
                $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>";
                }
@@ -233,7 +241,7 @@ class WP_Theme_Install_List_Table extends WP_Themes_List_Table {
         *     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 ) {
@@ -294,7 +302,7 @@ class WP_Theme_Install_List_Table extends WP_Themes_List_Table {
 
                ?>
                <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>
@@ -404,7 +412,7 @@ class WP_Theme_Install_List_Table extends WP_Themes_List_Table {
                        <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 ) ); ?>