The [removed] event is not firing in IE8

前端 未结 1 809
既然无缘
既然无缘 2021-01-21 11:21

I stripped down this javascript to be as simple as possible, and it\'s still not working in IE8.

function addLoadEvent(func) {
  var oldonload = window.onload;
          


        
相关标签:
1条回答
  • 2021-01-21 11:29

    The standard onload event won't work if another script is called using an HTML defer command.

    <script for="window" event="onload" defer="1">products.related();</script>

    Changing the above to use the standard addLoadEvent() function made it work.

    0 讨论(0)
提交回复
热议问题