HTML Purifier Plugin for Joomla


18th October 2010 in Coding Tags: joomla, open-source, programming

Html purifier is a Joomla plugin based on the HTML Purifier library.

This extension's goal is to clean the xhtml code of the Joomla content items from eventual validation errors.

It may be used also in another ways, for example to filter data coming from comments or forum posts to prevent XSS attacks.


After having installed the plugin, you need to activate it by going in "Extensions > Plugin manager > HTML purifier".

In the plugin page you will see also some options that you can tweak:

  • Tidy Level: High, Medium, Heavy;
  • Doctype: Xhtml 1.0 Transitional, Xhtml 1.0 strict, Html 4.0 Transitional, Html 4.0 Strict;
  • Linkify: converts automatically every string starting with http:// in a link.
  • Trusted HTML: if set "no" it doesn't allow to use script and style tags in Joomla content items.
  • Proprietary CSS: if set to "on" allows the use of non standard css properties.
  • HTML Purifier Cache: use HTML Purifier built in cache to avoid performance issues.

Deactivate specific content items just by inserting {disablepurifier}.

It would be good to insert the command in an HTML comment (using the HTML mode of your Joomla editor):

<!-- {disablepurifier} -->

This way you avoid showing the string {disablepurifier} in your content items if for some reason you deactivate the plugin.


Here it is a simple demo, but look at the official HTML Purifier demo to get a better idea.

Download Latest Version

Older versions

Older versionf of HTML Purifier for Joomla are also available.


5 November 2010 - thanks to Stefano Roncaglia

  • Added support for Joomla! 1.6
  • Created language folders and added Italian translation

18 October 2010

  • Updated htmlpurifier library to latest version (v4.2.0)
  • Added htmlpurifier_cache parameter
  • Added a fix to prevent target attribute to be stripped

28 April 2009

  • 0.3 correction of a bug for which in certain cases {disablepurifier} wouldn't work

9 February 2008

  • 0.2 version released GNU/GPL


I developed the plugin in late 2007 with Matteo Maria Baccano, another PHP programmer I was working with at that time.
After few months I ported it to Joomla 1.5 and released with GPL license.



  1. 1.

    Miami Web Design said:

    ( on 26th of October 2010 at 17:05 )

    good stuff

  2. 2.

    Marco Pivetta said:

    ( on 1st of December 2010 at 13:34 )

    Great job!
    I'm just goint to put it anywhere on any site I manage :D
    This plugin makes sense! Thank you!

  3. 3.

    John Sheyak said:

    ( on 23rd of June 2011 at 09:36 )

    Thanks for sharing this new plugin with all of us.Good job.Keep it up!

  4. 4.

    jakerusty said:

    ( on 6th of March 2012 at 13:03 )

    Thanks for providing such an useful information. You have provided me with the information what I was looking for a long time. keep posting!!!

  5. 5.

    public speaker said:

    ( on 6th of July 2012 at 07:58 )

    Good work. Found it meaningful!!

Leave your comment


Let's be social

Popular posts

Latest Comments

  1. Article Source a viral game app is not that much difficult. baaddedebbdccbek

    By Smithe443 in A Turning Point in my Life, Community Networks and OpenWISP

  2. Hi, I'm Julio , a web developer from Colombia, I'm working in a project with openwisp and I hope learn like you did. Maybe we can chat sometime about web design and open source software. Good look.

    By Julio in A Turning Point in my Life, Community Networks and OpenWISP

  3. Thank you for this good tips. It make my work more easy.

    By svarc in 10 Effective Business Card Design Tips

  4. brilliant thats good,keep on its really encouraging

    By paulas in 10 Effective Business Card Design Tips

  5. Thanks for this one, been going mad over it all day! Daft solution but very handy, thank you! Hate IE :-(

    By Netmatter in IE8 doesn't like 1x1px semi-transparent backgrounds

Popular Tags

censorship creativity criptography django google-summer-of-code ibiza inspiration javascript jquery linux nemesisdesign ninux open-source performance photo programming python security staticgenerator talk upload wireless-community