Is it possible to somehow make a setting that allows to specify that clicking a template should NOT replace all current content in the ckeditor?

Comments

guybedford’s picture

Status: Active » Closed (won't fix)

Unfortunately, these behavior seems to be hard coded into the ck editor templates as far as I can tell. So I'm not sure how to work around it. It may be worth trying another editor, as the others allow this behavior.

tostinni’s picture

Put this in your custom module:

function CUSTOM_MODULE_NAME_wysiwyg_editor_settings_alter(&$settings, &$context) {
  if ($context['profile']->editor == 'ckeditor') {
    $settings['templates_replaceContent'] = false;
  }
}
guybedford’s picture

Status: Closed (won't fix) » Fixed

Thanks! I've added this to the latest release.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

pakmanlh’s picture

Issue summary: View changes

JFTR as I hasn't been able to find the mentioned hook I made it work introducing the following configuration to the CKEditor directly:

config.templates_replaceContent = false;

Cheers and thanks for this great module.