Ticket #5921: script-loader.patch
| File script-loader.patch, 1.0 KB (added by azaozz, 5 years ago) |
|---|
-
script-loader.php
38 38 // Modify this version when tinyMCE plugins are changed. 39 39 $mce_version = apply_filters('tiny_mce_version', '20080221'); 40 40 $this->add( 'tiny_mce', '/wp-includes/js/tinymce/tiny_mce_config.php', array('editor_functions'), $mce_version ); 41 $this->localize( 'tiny_mce', 'wpTinyMCEConfig', array( 'defaultEditor' => wp_default_editor() ) );42 41 43 42 $this->add( 'prototype', '/wp-includes/js/prototype.js', false, '1.6'); 44 43 … … 484 483 return $js_array; 485 484 } 486 485 486 // These localizations require information that may not be loaded even by init 487 function wp_just_in_time_script_localization() { 488 wp_localize_script( 'tiny_mce', 'wpTinyMCEConfig', array( 'defaultEditor' => wp_default_editor() ) ); 489 } 490 491 add_filter( 'wp_print_scripts', 'wp_just_in_time_script_localization' ); 487 492 add_filter( 'print_scripts_array', 'wp_prototype_before_jquery' ); 488 493 489 494 ?>
