Ticket #28853: 28853.2.patch
File 28853.2.patch, 3.4 KB (added by , 11 years ago) |
---|
-
wp-admin/includes/class-wp-plugin-install-list-table.php
259 259 switch ( $status['status'] ) { 260 260 case 'install': 261 261 if ( $status['url'] ) { 262 $action_links[] = '<a class="install-now button" href="' . $status['url'] . '" title="' . esc_attr( sprintf( __( 'Install %s' ), $name ) ). '">' . __( 'Install Now' ) . '</a>';262 $action_links[] = '<a class="install-now button" href="' . $status['url'] . '" aria-labelledby="' . $plugin['slug'] . '">' . __( 'Install Now' ) . '</a>'; 263 263 } 264 264 265 265 break; 266 266 case 'update_available': 267 267 if ( $status['url'] ) { 268 $action_links[] = '<a class="button" href="' . $status['url'] . '" title="' . esc_attr( sprintf( __( 'Update to version %s' ), $status['version'] ) ). '">' . __( 'Update Now' ) . '</a>';268 $action_links[] = '<a class="button" href="' . $status['url'] . '" aria-labelledby="' . $plugin['slug'] . '">' . __( 'Update Now' ) . '</a>'; 269 269 } 270 270 271 271 break; … … 289 289 */ 290 290 $details_link = apply_filters( 'plugin_install_details_link', $details_link, $plugin ); 291 291 292 $action_links[] = '<a href="' . esc_attr( $details_link ) . '" class="thickbox" title="' . 293 esc_attr( sprintf( __( 'More information about %s' ), $name ) ) . '">' . __( 'More Details' ) . '</a>'; 292 $action_links[] = '<a href="' . esc_attr( $details_link ) . '" class="thickbox" aria-labelledby="' . $plugin['slug'] . '" data-title="' . esc_attr( $name ) . '">' . __( 'More Details' ) . '</a>'; 294 293 294 295 295 /** 296 296 * Filter the install action links for a plugin. 297 297 * … … 304 304 ?> 305 305 <div class="plugin-card"> 306 306 <div class="plugin-card-top"> 307 <div class="name column-name"<?php echo $style['name']; ?>><h4 ><a href="<?php echo esc_attr( $details_link ) ?>" class="thickbox"><?php echo $title; ?></a></h4>307 <div class="name column-name"<?php echo $style['name']; ?>><h4 id="<?php echo $plugin['slug']; ?>"><a href="<?php echo esc_attr( $details_link ) ?>" class="thickbox" data-title="<?php esc_attr_e( $name ); ?>"><?php echo $title; ?></a></h4> 308 308 <div class="action-links"> 309 309 <?php 310 310 if ( ! empty( $action_links ) ) { -
wp-admin/js/plugin-install.js
8 8 width = $( window ).width(), 9 9 H = $( window ).height() - ( ( 850 < width ) ? 60 : 20 ), 10 10 W = ( 850 < width ) ? 830 : width - 20; 11 11 12 12 if ( tbWindow.size() ) { 13 13 tbWindow.width( W ).height( H ); 14 14 $( '#TB_iframeContent' ).width( W ).height( H ); … … 38 38 tb_position(); 39 39 }); 40 40 41 $('.plugin s').on( 'click', 'a.thickbox', function() {41 $('.plugin-card').on( 'click', 'a.thickbox', function() { 42 42 tb_click.call(this); 43 43 44 44 $('#TB_title').css({'background-color':'#222','color':'#cfcfcf'}); 45 $('#TB_ajaxWindowTitle').html('<strong>' + plugininstallL10n.plugin_information + '</strong> ' + $(this).attr( 'title') );45 $('#TB_ajaxWindowTitle').html('<strong>' + plugininstallL10n.plugin_information + '</strong> ' + $(this).attr( 'data-title' ) ); 46 46 return false; 47 47 }); 48 48