Reputation: 327
I use an application that only supports basic HTML tags like p, font, ul, li etc. The CKEditor uses tags like "span", but the application does not support them. Is there any convenient solution to force the CKEditor to use basic html tags. specifically use the font tag instead of span tag to style words.
thanks
Upvotes: 0
Views: 640
Reputation: 1324
I found that Solution from Ckeditor Official Documentation, for more details refer Documentation
<body>
<textarea cols="80" id="editor1"
name="editor1" rows="10" data-
sample-shortt><p>This is
somee <strong>sample
textt</strong>. You are
usingg <a hreffff="https://ckeditor.com/"
;>CKEditor</a>.</p>.
</textarea>
<script>
CKEDITOR.replace('editor1', {
height: 280,
// List of text formats available for this editor instance.
format_tags: 'p;h1;h2;h3;h4;h5;h6;pre;address;div'
});
</script>
</body>
Edited based on your comment:-
config.colorButton_foreStyle = {
element: 'span',
attributes: { 'class': 'text-#(colorName)' }
};
config.colorButton_backStyle = {
element: 'span',
attributes: { 'class': 'text-#(colorName)' }
};
Please visit this page, & try as like this using your tag instead of Span tag
Upvotes: 1