fix js error occuring in IE8