wp/wp-admin/includes/class-wp-themes-list-table.php
changeset 22 8c2e4d02f4ef
parent 21 48c4eec2b7e6
equal deleted inserted replaced
21:48c4eec2b7e6 22:8c2e4d02f4ef
   187 			echo '</div>';
   187 			echo '</div>';
   188 		}
   188 		}
   189 	}
   189 	}
   190 
   190 
   191 	/**
   191 	/**
       
   192 	 * Generates the list table rows.
       
   193 	 *
       
   194 	 * @since 3.1.0
   192 	 */
   195 	 */
   193 	public function display_rows() {
   196 	public function display_rows() {
   194 		$themes = $this->items;
   197 		$themes = $this->items;
   195 
   198 
   196 		foreach ( $themes as $theme ) :
   199 		foreach ( $themes as $theme ) :
   206 
   209 
   207 			$activate_link = wp_nonce_url( 'themes.php?action=activate&amp;template=' . urlencode( $template ) . '&amp;stylesheet=' . urlencode( $stylesheet ), 'switch-theme_' . $stylesheet );
   210 			$activate_link = wp_nonce_url( 'themes.php?action=activate&amp;template=' . urlencode( $template ) . '&amp;stylesheet=' . urlencode( $stylesheet ), 'switch-theme_' . $stylesheet );
   208 
   211 
   209 			$actions             = array();
   212 			$actions             = array();
   210 			$actions['activate'] = sprintf(
   213 			$actions['activate'] = sprintf(
   211 				'<a href="%s" class="activatelink" title="%s">%s</a>',
   214 				'<a href="%s" class="activatelink" aria-label="%s">%s</a>',
   212 				$activate_link,
   215 				$activate_link,
   213 				/* translators: %s: Theme name. */
   216 				/* translators: %s: Theme name. */
   214 				esc_attr( sprintf( _x( 'Activate &#8220;%s&#8221;', 'theme' ), $title ) ),
   217 				esc_attr( sprintf( _x( 'Activate &#8220;%s&#8221;', 'theme' ), $title ) ),
   215 				_x( 'Activate', 'theme' )
   218 				_x( 'Activate', 'theme' )
   216 			);
   219 			);