CKEditor Wysiwyg hook

This hook stops CKEditor stripping out your syles, classes and ID's

/**
 * Implements hook_wysiwyg_editor_settings_alter().
 */
function d7dev_admin_wysiwyg_editor_settings_alter(&$settings, &$context) {
  if ($context['profile']->editor == 'ckeditor') {
   $settings['allowedContent'] = TRUE;
  }

}

You probably will want to also select /check Preformatted and Apply source formatting from Cleanup and Output admin/config/content/wysiwyg/profile/full_html/edit

Post your comment

Comments

No one has commented on this page yet.

RSS feed for comments on this page | RSS feed for all comments

Copywrite © 2017 Kevin Phillips All rights are reserved.

Proudly supporting opensource software