silverstripe/sapphire — pull request #793 by halkyon (2012-09-14 05:34:50+00:00)
Title: BUG HtmlEditorField doesn't save HTML fragments in HTMLValue correctly

The issue was raised in #7628 - http://open.silverstripe.org/ticket/7628, where an anchor tag was being changed from
`` to `` by `SS_HTMLValue`, when
HtmlEditorField::saveInto() parses the HTML fragments.

This is because SS_HTMLValue uses DOMDocument::saveXML() which is fine
for saving an XML document, but not suitable for HTML. This fixes that
to use DOMDocument::saveHTML() instead.