document.body.appendChild(i)

后端 未结 6 1294
傲寒
傲寒 2020-12-08 19:50

I am getting error only in IE7 as document.body is null; when I debug with Microsoft script editor I am getting the error in the following line: i.e.

6条回答
  •  伪装坚强ぢ
    2020-12-08 20:19

    If your script is inside head tag in html file, try to put it inside body tag. CreateElement while script is inside head tag will give you a null warning

    
      
    
    
    
      

    Game

提交回复
热议问题