Elxis CMS Forum

Support => General => Topic started by: xmanhattan on January 17, 2017, 13:23:23

Title: ckedit and fontawesome
Post by: xmanhattan on January 17, 2017, 13:23:23
Hello all,

I tried to add the plugin according to directions shown on  http://ckeditor.com/addon/fontawesome (http://ckeditor.com/addon/fontawesome)
so that I could see the icons inserted into the content using the file but
Code: [Select]
c:\wamp\www\test\includes\js\ckeditor\config.js but did not see the fontawesome added into the menu items.

I did not add
Code: [Select]
<script>CKEDITOR.dtd.$removeEmpty['span'] = false;</script> into index.php as I assume that Elxis may already have taken care of that.

Then I noticed that some of that code was already in config_full.js and tried to add it into there but it still did not work.

What am I doing wrong or does this mean that I have to enter the fontawesome code manually into the html?

I added
Code: [Select]
$eDoc->addFontAwesome(); before
Code: [Select]
elxisloader::loadFile('templates/flex/includes/flex.class.php')."\n"; and then this html code into the template index.php at the bottom to see if the fontawesome code  works and it does.

Code: [Select]
<ul class="fa-ul" style="padding:2px 0px 2px 5px;">
  <li><i class="fa-li fa fa-bomb"></i>List icons</li>
  <li><i class="fa-li fa fa-check-square"></i>can be used</li>
  <li><i class="fa-li fa fa-spinner fa-spin fa"></i>as bullets</li>
  <li><i class="fa-li fa fa-square"></i>in lists</li>
  <li><i class="fa-li fa fa-bolt"></i>as shown above</li>
</ul>

Title: Re: ckedit and fontawesome
Post by: nikos on January 17, 2017, 15:41:38
Try this $eDoc->addFontAwesomeAnim();
Title: Re: ckedit and fontawesome
Post by: xmanhattan on January 17, 2017, 16:07:40
Hello Niko,

I added that and commented out the other but I still do not see a button for it on the ckedit toolbar of the articles.

What am I doing wrong?
Title: Re: ckedit and fontawesome
Post by: datahell on January 17, 2017, 23:20:05
Don't mess CKeditor with that. Why you want to integrate fontawesomne with ckeditor? You use fontawesome from your css file, no need to touch html. Nikos can help you in that.
Title: Re: ckedit and fontawesome
Post by: xmanhattan on January 18, 2017, 10:04:43
Datahell,

Okay, I thought that it would make it easier.  I tried using it through a style just to see it working with a list item.

Maybe Nikos can provide a short example for the css file to make it easier.

Can you advise if changes can be made to add styles to the styles.js file or maybe another way to load additional styling?

Thank you
Title: Re: ckedit and fontawesome
Post by: nikos on January 18, 2017, 17:09:15
I am creating a topic about and I will post it soon.

I have posted a topic here (https://forum.elxis.org/index.php?topic=8803) with title Font Awesome usage in Elxis 4.5 and I hope this will help you.
Title: Re: ckedit and fontawesome
Post by: xmanhattan on January 19, 2017, 09:53:35
Okay, thank you Nikos