Changeset 3897:61304e9616a6 for plugins
- Timestamp:
- 10/01/18 11:24:07 (7 years ago)
- Branch:
- default
- Location:
- plugins
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
plugins/dcCKEditor/_post_config.php
r3769 r3897 108 108 <?php endif;?> 109 109 110 CKEDITOR.config.defaultLanguage = dotclear.user_language; 111 CKEDITOR.config.language = dotclear.user_language; 112 CKEDITOR.config.contentsLanguage = dotclear.user_language; 113 110 114 <?php 111 115 if (!empty($extraPlugins) && count($extraPlugins) > 0) { … … 237 241 238 242 CKEDITOR.on('instanceLoaded',function(e) { 239 240 243 // Retrieve textarea element of the instance, then its line-height (in px) and rows values, 241 244 // then apply line-height * rows (min = 6) to the inner height of the instance. … … 250 253 } 251 254 } 252 253 255 }); 254 256 … … 268 270 }); 269 271 272 const ta = document.getElementById(e.editor.name); 273 if (ta !== undefined) { 274 if (ta.lang && e.editor.config.contentsLanguage !== ta.lang) { 275 let config = e.editor.config; 276 config.contentsLanguage = ta.lang; 277 e.editor.destroy(); 278 CKEDITOR.replace(e.editor.name, config); 279 } 280 } 270 281 }); 271 282 -
plugins/dcCKEditor/inc/dc.ckeditor.behaviors.php
r3874 r3897 40 40 dcPage::jsVar('dotclear.base_url', $GLOBALS['core']->blog->host) . 41 41 dcPage::jsVar('dotclear.dcckeditor_plugin_url', DC_ADMIN_URL . self::$p_url) . 42 dcPage::jsVar('dotclear.user_language', $GLOBALS['core']->auth->getInfo('user_lang')) . 42 43 'CKEDITOR_GETURL = function(resource) { 43 44 // If this is not a full or absolute path. -
plugins/dcLegacyEditor/js/jsToolBar/jsToolBar.wysiwyg.js
r3880 r3897 188 188 } 189 189 190 // Set lang if set for the textarea 191 if (This.textarea.lang) { 192 doc.documentElement.setAttribute('lang', This.textarea.lang); 193 } 194 190 195 This.iwin = This.iframe.contentWindow; 191 196 -
plugins/pages/page.php
r3878 r3897 487 487 '<p class="area" id="excerpt-area"><label for="post_excerpt" class="bold">' . __('Excerpt:') . ' <span class="form-note">' . 488 488 __('Introduction to the page.') . '</span></label> ' . 489 form::textarea('post_excerpt', 50, 5, html::escapeHTML($post_excerpt)) . 489 form::textarea('post_excerpt', 50, 5, 490 [ 491 'default' => html::escapeHTML($post_excerpt), 492 'extra_html' => 'lang="' . $post_lang . '"' 493 ]) . 490 494 '</p>', 491 495 … … 496 500 [ 497 501 'default' => html::escapeHTML($post_content), 498 'extra_html' => 'required placeholder="' . __('Content') . '" '502 'extra_html' => 'required placeholder="' . __('Content') . '" lang="' . $post_lang . '"' 499 503 ]) . 500 504 '</p>',
Note: See TracChangeset
for help on using the changeset viewer.