hasUTF8BOM not set in HTML

Issue #19 resolved
Former user created an issue

Original [issue 19](https://code.google.com/p/okapi/issues/detail?id=19) created by @ysavourel on 2009-03-10T02:55:20.000Z:

In the same html example file as for issue comment 18\. (ruby.htm), the origianl file is UTF-8 and has a BOM. When the START\_DOCUMENT event is sent, the resource has the method hasUTF8BOM() returning false. It should be true. This prevent the writer to pre-pend the BOM as it should.

Comments (3)

  1. Former user Account Deleted

    Comment [2.](https://code.google.com/p/okapi/issues/detail?id=19#c2) originally posted by @ysavourel on 2009-03-11T17:21:26.000Z:

    This code passes - so we know the detector is working - I will look at the filter next

    InputStream htmlStream = HtmlDetectBomTest.class.getResourceAsStream("/ruby.html");

    BOMNewlineEncodingDetector bomDetector = new BOMNewlineEncodingDetector(htmlStream);

    assertTrue(bomDetector.hasBom()); assertTrue(bomDetector.hasUtf8Bom()); assertFalse(bomDetector.hasUtf7Bom());

  2. Log in to comment