Switch the Html Cleaner from Tidy to the Html Agility Pack

  • Updated

Some users have experienced issues with the cleanup that is done on Html when published in the workarea. The publishing function cleans html to make sure tags are correct and sometimes strips out formatting that you do not wish. There is a new key in version 9.1 SP1 CU 22+ that allows you to change the default validator. Below are the options available.

Option 1

 <add key="HtmlValidator" value="tidy" />

This is the default validator shipped with the product and the one that has been used on all versions. The source code for the project is no longer maintained as it is a 3rd party dll that is being used.

Option 2

 <add key="HtmlValidator" value="agilitypack" />

The HTMl Agility Pack is an html parser that supports newer standards in html and has better support for newer tags that have been added in the recent years. 


If the default Tidy key is not working for you, try swapping Tidy for AgilityPack in the key in the web.config file (App setting) to see if it works better for your organization.