Fixes for IE8 related bugs