Made changes for IE8 compat