ImpressCMS has a reputation as a secure platform, and security is also one of our principal values we adhere to. Every time we think of making a change, we ask ourselves "Will this have an impact on security?". In our current standard configuration, that security setup impedes us from using Font Awesome in our text fields, which is a pity. Let's fix that.
HTMLPurifier is one of the tools we use to obtain our current level of security, but in order to use Font Awesome, we'll need to make some small changes to the standard configuration in order to stop HTMLPurifier from stripping out the relevant HTML constructs.
In short, what we need to do is add the class attributes for the span and i tags to the authorised attribute list. If you don't know how to do that, read on.
- Once you have logged in to your site go to the administration panel at yoursite/admin.php
- There, choose Preferences > HTMLPurifier Settings (yoursite/modules/system/admin.php?fct=preferences&op=show&confcat_id=14)
- Make sure the 'allowed elements' include both 'span' and 'i'
- Add 'i.class' and 'span.class' to the field 'Allowed Attributes'
Start using Font Awesome by adding the relevant CSS line to your theme.