1<?php use Fisharebest\Webtrees\Module; ?> 2<?php use Fisharebest\Webtrees\View; ?> 3 4<?php if (Module::getModuleByName('ckeditor')) : ?> 5 <?php View::push('javascript') ?> 6 <script src="<?= e(WT_CKEDITOR_BASE_URL) ?>ckeditor.js"></script> 7 <script src="<?= e(WT_CKEDITOR_BASE_URL) ?>adapters/jquery.js"></script> 8 9 <script> 10 var CKEDITOR_BASEPATH = <?= json_encode(WT_CKEDITOR_BASE_URL) ?>; 11 12 // Enable for all browsers 13 CKEDITOR.env.isCompatible = true; 14 15 // Disable toolbars 16 CKEDITOR.config.removePlugins = "forms,newpage,preview,print,save,templates"; 17 CKEDITOR.config.extraAllowedContent = "area[shape,coords,href,target,alt,title];map[name];img[usemap];*[class,style]"; 18 19 // Activate the editor 20 $("textarea.html-edit").ckeditor(function(config){config.removePlugins = "forms";}, { 21 language: "<?= strtolower(WT_LOCALE) ?>" 22 }); 23 </script> 24 <?php View::endpush() ?> 25<?php endif ?> 26