Skip to content

Firefox and Invalid XHTML

Just an FYI for anyone using the “application/xhtml+xml” content type on their site or web app. If you try to insert a piece of HTML that isn’t valid XHTML, you will get the following error:

uncaught exception: [Exception… “Component returned failure code: 0x80004003 (NS_ERROR_INVALID_POINTER) [nsIDOMNSHTMLElement.innerHTML]” nsresult: “0x80004003 (NS_ERROR_INVALID_POINTER)” location: “JS frame :: https:/example.com/jquery.js :: anonymous :: line 911” data: no]

Fix up your markup and you should be good to go.