zombiesbyte Posted September 4, 2016 Share Posted September 4, 2016 Hi Guys Just thought I'd post a solution to an issue I was facing. I couldn't find any solutions on here so thought this may come in handy for anyone facing the same problem. In the admin area of CC, if you try to use a Font Awesome (or any element that uses <i> I believe) FCK Editor (the WYSIWYG / Rich Text Editor) it will strip these tags without warning. I just happened to notice they were missing today so here's the fix: In your /includes/ckeditor folder there should be a config.js file. Add the following line at the bottom before the closing brace: // ALLOW <i></i> config.protectedSource.push(/<i[^>]*><\/i>/g); So for a clearer idea for those who don't do a lot of programming here's the default updated version: /** * @license Copyright (c) 2003-2016, CKSource - Frederico Knabben. All rights reserved. * For licensing, see LICENSE.md or http://ckeditor.com/license */ CKEDITOR.editorConfig = function( config ) { config.filebrowserBrowseUrl = document.location.pathname+'?_g=filemanager&mode=fck'; config.protectedSource.push(/{[\s\S]*?}/g); config.extraPlugins = 'showprotected'; config.filebrowserWindowHeight = 500; config.filebrowserWindowWidth = 650; config.allowedContent = true; // ALLOW <i></i> config.protectedSource.push(/<i[^>]*><\/i>/g); }; One final thing is that the editor may have cached the previous settings so I would advise a clear out of your browser history or Ctrl + F5 a few times with the editor open in your admin area before inserting your font-awesome icons into the source code view. Remember to switch back from source view to normal view before saving and testing your new awesome page Happy days Cheers James Mod: I think this is an open and close thread so feel free to mark it so Quote Link to comment Share on other sites More sharing options...
Dirty Butter Posted September 4, 2016 Share Posted September 4, 2016 Thanks! I had tried using italics before, and now I know why it didn't work lol. Quote Link to comment Share on other sites More sharing options...
Al Brookbanks Posted September 5, 2016 Share Posted September 5, 2016 Can you have more than one config value of this? Are smarty tags still respected? If so then yes it looks like you can. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.