Site offline - umbracoLog says "The document does not have a root element"
Hi all,
Suddenly the site is offline. We can log in to backend. We can publish without error messages in ui. But nothing is actually published. Looking at the umbracoLog I find:
Xml wasn't saved: System.Xml.XmlException: Invalid XML document, The document does not have a root element.. at System.Xml.XmlDocument.Save(String filename) at umbraco.content.SaveContentToDisk(XmlDocument xmlDoc)
This is an old Umbraco 3.05 which has been running for ages without any problems. And there's been no developer activities on it.
Any experience with that?
I've tried:
Rightclick content node and Republish whole structure. UI says great. Log says the above. Site remains offline.
Rightclick root node and publish (all nodes). UI says great. Log says the above. Site remains offline.
Unpublish all. Create one new node. Publish. Log says the above. Site remains offline.
Ps. A regex to find control characters that can be used in regexr.com: (?![\uD800-\uDBFF])[\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x9F\uFEFF\uFFFE\uFFFF]
Site offline - umbracoLog says "The document does not have a root element"
Hi all,
Suddenly the site is offline. We can log in to backend. We can publish without error messages in ui. But nothing is actually published. Looking at the umbracoLog I find:
This is an old Umbraco 3.05 which has been running for ages without any problems. And there's been no developer activities on it.
Any experience with that?
I've tried:
best
Jesper
Hi Jesper,
It's definitely got to do with the Umbraco.config file (it's a generic XML error).
I seem to remember having had a similar error recently on a newer site, where I deleted the Umbraco.config, and hit the site again...
Though all logic tells me that the steps you've already tried should have performed something similar already.
/Chriztian
Could it be that there's illegal characters copy/pasted into the content in the backoffice?
Open up umbraco.config in Notepad++ (or something like it) and see if there's control characters that show up.
Also check in an xml validator if the xml is valid and if not, where it is invalid, that might help.
Ps. A regex to find control characters that can be used in regexr.com:
(?![\uD800-\uDBFF])[\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x9F\uFEFF\uFFFE\uFFFF]
is working on a reply...