WordPress.org

Make WordPress Core

Changeset 12677


Ignore:
Timestamp:
01/09/10 01:17:45 (6 years ago)
Author:
azaozz
Message:

Show error message in TB when iframes support is turned off in the browser, props nacin, fixes #10939

Location:
trunk/wp-includes
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-includes/js/thickbox/thickbox.js

    r12276 r12677  
    4141            jQuery("html").css("overflow","hidden"); 
    4242            if (document.getElementById("TB_HideSelect") === null) {//iframe to hide select elements in ie6 
    43                 jQuery("body").append("<iframe id='TB_HideSelect'></iframe><div id='TB_overlay'></div><div id='TB_window'></div>"); 
     43                jQuery("body").append("<iframe id='TB_HideSelect'>"+thickboxL10n.noiframes+"</iframe><div id='TB_overlay'></div><div id='TB_window'></div>"); 
    4444                jQuery("#TB_overlay").click(tb_remove); 
    4545            } 
     
    199199                    jQuery("#TB_iframeContent").remove(); 
    200200                    if(params['modal'] != "true"){//iframe no modal 
    201                         jQuery("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'><a href='#' id='TB_closeWindowButton' title='"+thickboxL10n.close+"'><img src='" + tb_closeImage + "' /></a></div></div><iframe frameborder='0' hspace='0' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;' > </iframe>"); 
     201                        jQuery("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'><a href='#' id='TB_closeWindowButton' title='"+thickboxL10n.close+"'><img src='" + tb_closeImage + "' /></a></div></div><iframe frameborder='0' hspace='0' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;' >"+thickboxL10n.noiframes+"</iframe>"); 
    202202                    }else{//iframe modal 
    203203                    jQuery("#TB_overlay").unbind(); 
    204                         jQuery("#TB_window").append("<iframe frameborder='0' hspace='0' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;'> </iframe>"); 
     204                        jQuery("#TB_window").append("<iframe frameborder='0' hspace='0' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;'>"+thickboxL10n.noiframes+"</iframe>"); 
    205205                    } 
    206206            }else{// not an iframe, ajax 
  • trunk/wp-includes/script-loader.php

    r12654 r12677  
    166166    $scripts->add_data( 'jquery-table-hotkeys', 'group', 1 ); 
    167167 
    168     $scripts->add( 'thickbox', "/wp-includes/js/thickbox/thickbox.js", array('jquery'), '3.1-20091124'); 
     168    $scripts->add( 'thickbox', "/wp-includes/js/thickbox/thickbox.js", array('jquery'), '3.1-20100108'); 
    169169    $scripts->add_data( 'thickbox', 'group', 1 ); 
    170170    $scripts->localize( 'thickbox', 'thickboxL10n', array( 
     
    174174            'of' => __('of'), 
    175175            'close' => __('Close'), 
     176            'noiframes' => __('This feature requires inline frames. You have iframes disabled or your browser does not support them.'), 
    176177            'l10n_print_after' => 'try{convertEntities(thickboxL10n);}catch(e){};' 
    177178    ) ); 
Note: See TracChangeset for help on using the changeset viewer.