Ticket #3958: 3958.diff

File 3958.diff, 3.8 kB (added by Nazgul, 1 year ago)
  • wp-includes/js/quicktags.js

    old new  
    168168} 
    169169 
    170170function edShowLinks() { 
    171         var tempStr = '<select onchange="edQuickLink(this.options[this.selectedIndex].value, this);"><option value="-1" selected>(Quick Links)</option>'; 
     171        var tempStr = '<select onchange="edQuickLink(this.options[this.selectedIndex].value, this);"><option value="-1" selected>' + quicktagsL10n.quickLinks + '</option>'; 
    172172        for (i = 0; i < edLinks.length; i++) { 
    173173                tempStr += '<option value="' + i + '">' + edLinks[i].display + '</option>'; 
    174174        } 
     
    248248                } 
    249249        } 
    250250        if (word == '') { 
    251                 word = prompt('Enter a word to look up:', ''); 
     251                word = prompt(quicktagsL10n.wordLookup, ''); 
    252252        } 
    253253        if (word !== null && /^\w[\w ]*$/.test(word)) { 
    254254                window.open('http://www.answers.com/' + escape(word)); 
     
    260260        for (i = 0; i < edButtons.length; i++) { 
    261261                edShowButton(edButtons[i], i); 
    262262        } 
    263         document.write('<input type="button" id="ed_spell" class="ed_button" onclick="edSpell(edCanvas);" title="Dictionary lookup" value="lookup" />'); 
    264         document.write('<input type="button" id="ed_close" class="ed_button" onclick="edCloseAllTags();" title="Close all open tags" value="Close Tags" />'); 
     263        document.write('<input type="button" id="ed_spell" class="ed_button" onclick="edSpell(edCanvas);" title="' + quicktagsL10n.dictionaryLookup + '" value="' + quicktagsL10n.lookup + '" />'); 
     264        document.write('<input type="button" id="ed_close" class="ed_button" onclick="edCloseAllTags();" title="' + quicktagsL10n.closeAllOpenTags + '" value="' + quicktagsL10n.closeTags + '" />'); 
    265265//      edShowLinks(); // disabled by default 
    266266        document.write('</div>'); 
    267267} 
     
    366366                defaultValue = 'http://'; 
    367367        } 
    368368        if (!edCheckOpenTags(i)) { 
    369                 var URL = prompt('Enter the URL' ,defaultValue); 
     369                var URL = prompt(quicktagsL10n.enterURL, defaultValue); 
    370370                if (URL) { 
    371371                        edButtons[i].tagStart = '<a href="' + URL + '">'; 
    372372                        edInsertTag(myField, i); 
     
    378378} 
    379379 
    380380function edInsertImage(myField) { 
    381         var myValue = prompt('Enter the URL of the image', 'http://'); 
     381        var myValue = prompt(quicktagsL10n.enterImageURL, 'http://'); 
    382382        if (myValue) { 
    383383                myValue = '<img src="'  
    384384                                + myValue  
    385                                 + '" alt="' + prompt('Enter a description of the image', '')  
     385                                + '" alt="' + prompt(quicktagsL10n.enterImageDescription, '')  
    386386                                + '" />'; 
    387387                edInsertContent(myField, myValue); 
    388388        } 
  • wp-includes/script-loader.php

    old new  
    1313                $this->add( 'dbx', '/wp-includes/js/dbx.js', false, '2.05' ); 
    1414                $this->add( 'fat', '/wp-includes/js/fat.js', false, '1.0-RC1_3660' ); 
    1515                $this->add( 'sack', '/wp-includes/js/tw-sack.js', false, '1.6.1' ); 
    16                 $this->add( 'quicktags', '/wp-includes/js/quicktags.js', false, '3517' ); 
     16                $this->add( 'quicktags', '/wp-includes/js/quicktags.js', false, '3958' ); 
     17                $this->localize( 'quicktags', 'quicktagsL10n', array( 
     18                        'quickLinks' => __('(Quick Links1)'), 
     19                        'wordLookup' => __('Enter a word to look up:'), 
     20                        'dictionaryLookup' => __('Dictionary lookup'), 
     21                        'lookup' => __('lookup'), 
     22                        'closeAllOpenTags' => __('Close all open tags'), 
     23                        'closeTags' => __('close tags'), 
     24                        'enterURL' => __('Enter the URL'), 
     25                        'enterImageURL' => __('Enter the URL of the image'), 
     26                        'enterImageDescription' => __('Enter a description of the image') 
     27                ) ); 
    1728                $this->add( 'colorpicker', '/wp-includes/js/colorpicker.js', false, '3517' ); 
    1829                $this->add( 'tiny_mce', '/wp-includes/js/tinymce/tiny_mce_gzip.php', false, '20070326' ); 
    1930                $mce_config = apply_filters('tiny_mce_config_url', '/wp-includes/js/tinymce/tiny_mce_config.php');