I am using pdf2htmlEX tool to convert PDF documents into HTML5 content. The tool works fine, gives me great results. I do have one problem with case-sensitive class names that is applied to a page background image.
pdf2htmlEX generates HTML files for every PDF page along with two CSS files that define page containers and place elements within each page. I use this HTML and CSS in my web app to display this content. Everything works fine except the position of background image in some cases.
The problem is following. Each page background image has one of these two classes applied to it (generated by pdf2htmlEX):
.Bi { /* images that occupies the whole page */
position:absolute;
border:0;
margin:0;
top:0;
bottom:0;
width:100%;
height:100%;
-ms-user-select:none;
-moz-user-select:none;
-webkit-user-select:none;
user-select:none;
}
.bi { /* images that cover only a part of the page */
position:absolute;
border:0;
margin:0;
-ms-user-select:none;
-moz-user-select:none;
-webkit-user-select:none;
user-select:none;
}
When I open the preview HTML page generated by pdf2htmlEX then only ".bi" or ".Bi" style is applied to that background image. You can see that here in Firebug image, which styles are applied:
Same HTML inserted into my app applies both classes to this image, resulting in mis-placement in some cases... See the same HTML and firebug image for styles applied in my weba app:
How is this possible? CSS selectors and class names are case-insensitive right?