Reputation: 917
my ckeditor has this configuration: config.allowedContent = true
If I insert this code into my editor:
<div class="col-xs-12">
<input type="text" name="LastName" class="form-control" id="LastName">
<div class="help-block animated fadeInDown">
<span id="errLastNameMsg"></span>
</div>
</div>
this is a simple id <span id="errLastNameMsg"></span> with span content.
After Ckeditor compile it is.
<div class="col-xs-12"><input class="form-control" id="LastName"
name="LastName" type="text" />
<div class="help-block animated fadeInDown"> </div>
</div>
It Strip <span id="errLastNameMsg"></span> with
thanks in advance for your's solution.
Upvotes: 0
Views: 730
Reputation: 3151
CKEditor has an option for ignoring elements if empty: CKEDITOR.dtd.$removeEmpty
By default, empty span elements are removed.
Use this to allow empty span elements:
CKEDITOR.dtd.$removeEmpty.span = 0;
Upvotes: 2