welcome to feimos's blog
This is your first time to visit this webSite.
Each browser has a list of HTML elements it supports. Elements not on the list will be considered unknown elements. The browser will not set any styles for unknown elements (different browsers will have different default styles for elements). In versions prior to IE9, unknown elements cannot be styled. The DOM of unknown elements is also displayed incorrectly, and IE inserts an empty node with no child elements into the DOM. All elements that you would have thought would be children of this unknown element will become its siblings.
There is a solution to this problem. Use js to create a fake article element before using the article tag. IE will recognize this element and support setting styles with css. This fake element doesn't even need to be inserted into the DOM.
Please see the following example:
This is your first time to visit this webSite.
But if we add a js sentence in the head, the situation will be different immediately.
We can create a fake copy of all new HTML5 elements once, so we don’t have to worry about browsers that don’t support HTML5 well in the future. Remy Sharp's HTML5 enabling script helps us do these things. The basic idea of the script is as follows:
This script has been hosted on Google Project Hosting. You can directly link to this script: