Prevent media upload links from being clicked before lightbox is ready to handle them. fixes #15621

git-svn-id: http://svn.automattic.com/wordpress/trunk@16669 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
markjaquith 2010-12-01 20:41:47 +00:00
parent 57d6d72d2f
commit 5f15bf9db2
1 changed files with 1 additions and 1 deletions

View File

@ -383,7 +383,7 @@ function media_buttons() {
add_action( 'media_buttons', 'media_buttons' ); add_action( 'media_buttons', 'media_buttons' );
function _media_button($title, $icon, $type) { function _media_button($title, $icon, $type) {
return "<a href='" . esc_url( get_upload_iframe_src($type) ) . "' id='add_$type' class='thickbox' title='$title'><img src='" . esc_url( admin_url( $icon ) ) . "' alt='$title' /></a>"; return "<a href='" . esc_url( get_upload_iframe_src($type) ) . "' id='add_$type' class='thickbox' title='$title'><img src='" . esc_url( admin_url( $icon ) ) . "' alt='$title' onclick='return false;' /></a>";
} }
function get_upload_iframe_src($type) { function get_upload_iframe_src($type) {