Articles


How to prevent stripping of i tags from ckeditor?

How to prevent stripping of i tags from ckeditor?



Posted bysivaprasad,1st Sep 2016

When we edit the i tags that we already used inside ckeditor will strips out. This will continue every time when we open the ckeditor. Here is the solution for this problem.

 

  1. Goto administration->configuration->content authoring->ck editor. (admin/config/content/ckeditor)
  2. Then goto profiles->full html-> edit
  3. There click on the advanced options.
  4. On the text box 'Custom JavaScript configuration'

Paste the code below

config.allowedContent = true;

config.extraAllowedContent = 'p(*)[*]{*};div(*)[*]{*};li(*)[*]{*};ul(*)[*]{*}';

CKEDITOR.dtd.$removeEmpty.i = 0;

Save this and goto ckeditor and we can find that the i tag is not stripping out now.