GetSimple Support Forum

Full Version: Font Awesome tags disappear after saving change in source html
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello,

The text editor in source format from Get Simple 3.3.2 is unable to preserve the class attribute code from Font Awesome. For example,
Code:
<ul class="fa-ul">
    <li><span class="fa-li fa fa-check"></i> We stand by our work with a 100% guarantee of excellent service</li>
</ul>
Where fa are the classt attribute provided by Font Awesome. Use the example from the url to reproduce the issue.
ckeditor deletes empty tags
add to config.js

// prevent removal of empty tags
CKEDITOR.dtd.$removeEmpty['i'] = false;

there is more details in forums somewhere
Thank you very much. The above solution worked. It will be nice to document the suggestion on the main page.
Regards,

Luya
I think it would be good to include it in the core.
It has been for <i> and <span> , but they are commented out, we cannot decide how to handle this and which elements to remove for the user.

// prevent removal of empty inline tags
// CKEDITOR.dtd.$removeEmpty['i'] = false;
// CKEDITOR.dtd.$removeEmpty['span'] = false;

If you guys can vote on what elements should be included and if this is a innocuous change, I will consider it.
Font awesome goes with bootstrap - it's pretty popular. atm every upgrade of GS is going to require digging into the admin folder and editing config.js .
There is an alternative work-around:

The recommended font awesome syntax is [example]
Code:
<i class="fa fa-camera-retro"></i>
If you take the unicode from the cheat sheet you can use that instead, ie
Code:
<i class="fa">&#xf083;</i>
Seems to work. No empty tags.
No your supposed to use your own config.js
Nice workaround.
I'm using &nbsp; to prevent editor to remove the empty tag,


<i class="*** ***">&nbsp;</i>

Alex
(2014-11-21, 04:06:18)shawn_a Wrote: [ -> ]It has been for <i> and <span> , but they are commented out, we cannot decide how to handle this and which elements to remove for the user.

// prevent removal of empty inline tags
// CKEDITOR.dtd.$removeEmpty['i'] = false;
// CKEDITOR.dtd.$removeEmpty['span'] = false;

If you guys can vote on what elements should be included and if this is a innocuous change, I will consider it.

Thanks for this solution! That was driving me nuts
shfn_a
It has been for <i> and <span> , but they are commented out, we cannot decide how to handle this and which elements to remove for the user.

// prevent removal of empty inline tags
// CKEDITOR.dtd.$removeEmpty['i'] = false;
// CKEDITOR.dtd.$removeEmpty['span'] = false;

If you guys can vote on what [**SPAM LINK REMOVED**] elements should be included and if this is a innocuous change, I will consider it.

Does Get Simple support Font Awesome these days or do we still need to configure the config.js every time?
Those 2 specific fixes are already present in stable