Hello, On 2/5/2014 2:45 PM, libreoffice-ml.mbourne@spamgourmet.com wrote:
Uploading the document to the W3C validator (http://validator.w3.org/) it appears the DOCTYPE is not valid. It should be:Not only that; there should be a reference to http://www.w3.org/TR/html4/loose.dtd at the end of the DOCTYPE section! The HTML DOCTYPE is messed up.-//W3C//DTD HTML 4.0 Transitional//EN (the file is missing "//EN" from the end).
Unfortunately, the corrected syntax doesn't fix a thing. I think the LibreOffce HTML parser might not handle DOCTYPEs correctly? It worked in previous versions. If I were to put a comment like <!-- Hello world --> or something else into the HTML file (DOCTYPE removed), the parser recognizes it. Even inserting <!THISISNOTADOCTYPE> works. It is just when there is a DOCTYPE, even with correct syntax, that the LibreOffice HTML parser is tripped.The original document doesn't fail with the version of LO I have, so cannot check, but try correcting the DOCTYPE. If that allows the file to open as expected, it appears the problem is with moneydance producing invalid output, rather than with LO.
Arbitrarily changing the DOCTYPE to indicate HTML5 may well also fail, as the rest of the document is not valid HTML5.Mark.
Regards, xmlhttprequest.open@gmail.com
null wrote:Hello, It looks like the problem is with LibreOffice interpreting DOCTYPEs. You see, every HTML is supposed to have a DOCTYPE at the top of the file, explaining what version of HTML (HTML5, HTML4.01, etc) the file uses. The file you uploaded has a DOCTYPE of HTML4.01 Transitional. Anyway, if I remove the <!DOCTYPE ...> part of the HTML file, and reopen it in LibreOffice, it works just fine, and shows the file's contents (not the source). Even switching the DOCTYPE to <!DOCTYPE html> (HTML5) causes the problem. So, in theory, if you want to view an HTML file in LibreOffice 4.2, you have to remove its <!DOCTYPE ...>, and it will work fine. Would you like an official bug to be filed so that the developers know of the problem and can try to fix it? Regards, xmlhttprequest.open@gmail.com On 2/5/2014 12:05 AM, Keith Bates wrote:I've produced a document that doesn't work with LO. It is at https://www.dropbox.com/s/mbylcso4r2qm2r2/test.html Strangely it does open in Abiword. Earlier documents produced by moneydance as recently as last month open fine in LO. I have not upgraded moneydance in that time. Having quickly opened about 20 html's the problem is limited to those produced lately by moneydance. I haven't had time to look closely at the html source. I suppose it's possible that LO is now being more strict in its interpretation. The work around in the short term might be to use Abiword..
-- To unsubscribe e-mail to: users+unsubscribe@global.libreoffice.org Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/ Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette List archive: http://listarchives.libreoffice.org/global/users/ All messages sent to this list will be publicly archived and cannot be deleted