fixing html and head tags missing
added support for IE 8 / 9