Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I turn off XHTML validation in Sitecore?

How do I turn off Sitecore (6.5) XHTML Validation of pages in workflow?

I'm developing and keep running into issues while trying to publish down test pages because they error out. I would prefer to just get the errors as stacktraces in the browser.

I'm not sure if I have changed something before this does this, but I've recently taken on a project to move a Sitecore into a multi-site solution.

I did not have these issues while developing the solution the first time but I was using 6.4 instead of 6.5.

like image 206
al3xnull Avatar asked Dec 09 '11 21:12

al3xnull


People also ask

What is XHTML validation?

Every XHTML document is validated against a Document Type Definition. Before validating an XHTML file properly, a correct DTD must be added as the first or second line of the file. Once you are ready to validate your XHTML document, you can use W3C Validator to validate your document.

Is valid XHTML field must be a valid XHTML document?

When using HTML5 in item presentation or adding HTML5 tags to item fields (for example, a Rich Text field), default Sitecore item and field validation may fail. The item must render as a valid XHTML document. Field must be a valid XHtml document.


2 Answers

If you go into System -> Settings -> Validation Rules -> Global Rules if you scroll to the bottom you will see the Workflow section.

You can remove the XHTML validation rule from there.

Hope this helps :)

like image 188
Stephen Pope Avatar answered Sep 21 '22 08:09

Stephen Pope


I was able to get this to work by going to the following item: /sitecore/system/Settings/Validation Rules/Field Types/Rich Text

From that item, remove the 'Is Xhtml' option from each of the Quick Action Bar, Validate Button, Validator Bar & Workflow fields.

This should disable the XHTML Validation.

like image 42
Juzzbott Avatar answered Sep 21 '22 08:09

Juzzbott