Changeset 7513 for trunk/wp-includes/js/tinymce/tiny_mce_config.php
- Timestamp:
- 03/26/2008 03:22:53 AM (18 years ago)
- File:
-
- 1 edited
-
trunk/wp-includes/js/tinymce/tiny_mce_config.php (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/js/tinymce/tiny_mce_config.php
r7489 r7513 59 59 60 60 /* 61 Setting mce_valid_elements to *[*] skips all of the internal cleanup and can cause problems.62 The minimal setting would be -strong/-b[*],-em/-i[*],*[*].63 Best is to use the default cleanup by not specifying mce_valid_elements. It contains full set of XHTML 1.0.64 If others are needed, mce_extended_valid_elements can be used to add to it, or mce_invalid_elements to remove.65 */66 $valid_elements = apply_filters('mce_valid_elements', '');67 $invalid_elements = apply_filters('mce_invalid_elements', '');68 $extended_valid_elements = apply_filters('mce_extended_valid_elements', '');69 70 /*71 61 The following filter allows localization scripts to change the languages displayed in the spellchecker's drop-down menu. 72 62 By default it uses Google's spellchecker API, but can be configured to use PSpell/ASpell if installed on the server. … … 105 95 if ( ! empty($mce_external_languages) ) { 106 96 foreach ( $mce_external_languages as $name => $path ) { 107 if ( is_ readable($path) ) {97 if ( is_file($path) && is_readable($path) ) { 108 98 include_once($path); 109 99 $ext_plugins .= $strings; … … 163 153 'apply_source_formatting' => false, 164 154 'remove_linebreaks' => true, 155 'paste_auto_cleanup_on_paste' => true, 156 'paste_convert_middot_lists' => true, 157 'paste_remove_spans' => true, 158 'paste_remove_styles' => true, 159 'paste_strip_class_attributes' => 'all', 165 160 'gecko_spellcheck' => true, 166 161 'entities' => '38,amp,60,lt,62,gt', … … 176 171 ); 177 172 178 if ( $valid_elements ) $initArray['valid_elements'] = $valid_elements;179 if ( $extended_valid_elements ) $initArray['extended_valid_elements'] = $extended_valid_elements;180 if ( $invalid_elements ) $initArray['invalid_elements'] = $invalid_elements;181 182 173 // For people who really REALLY know what they're doing with TinyMCE 183 // You can modify initArray to add, remove, change elements of the config before tinyMCE.init 184 $initArray = apply_filters('tiny_mce_before_init', $initArray); // changed from action to filter 174 // You can modify initArray to add, remove, change elements of the config before tinyMCE.init (changed from action to filter) 175 $initArray = apply_filters('tiny_mce_before_init', $initArray); 176 177 // Setting "valid_elements", "invalid_elements" and "extended_valid_elements" can be done through "tiny_mce_before_init". 178 // Best is to use the default cleanup by not specifying valid_elements, as TinyMCE contains full set of XHTML 1.0. 185 179 186 180 // support for deprecated actions … … 229 223 if ( $disk_cache ) { 230 224 231 $cacheKey = apply_filters('tiny_mce_version', '2008032 3');225 $cacheKey = apply_filters('tiny_mce_version', '20080325'); 232 226 233 227 foreach ( $initArray as $v ) … … 308 302 $content = gzencode( $content, 9, FORCE_GZIP ); 309 303 } 304 305 // Stream to client 306 header( 'Content-Length: ' . strlen($content) ); 307 echo $content; 310 308 311 309 // Write file … … 328 326 @unlink("$cache_path/$key"); 329 327 330 if ( putFileContents( $cache_file, $content ) && is_readable($cache_file) ) { 331 $mtime = gmdate( "D, d M Y H:i:s", filemtime($cache_file) ) . " GMT"; 332 header( 'Last-Modified: ' . $mtime ); 333 header( 'Cache-Control: must-revalidate', false ); 334 } 335 } 336 337 // Stream to client 338 header( 'Content-Length: ' . strlen($content) ); 339 echo $content; 328 putFileContents( $cache_file, $content ); 329 } 330 340 331 ?>
Note: See TracChangeset
for help on using the changeset viewer.