IE9中input事件与异步事件连用会发生跨域问题

IE版本中IE8以及IE9以上版本不会存在这个问题唯独IE9

发生跨域问题代码

$("#stock_code").bind("input",function(e){
    if($.string.isNumeric($(page_id+" #stock_code").val()))
    {
      if($(page_id+" #stock_code").val().length>3)
      {
          xxx(); //异步事件
      }
    }else{
      if($(page_id+" #stock_code").val().length>1)
      {
          xxx(); //异步事件
      }    
    }
});

解决跨域问题解决方法:

  异步事件xxx() 调用一个定时器任务  setTimeout(xxx,1);

原文地址:https://www.cnblogs.com/laoniaofly/p/6884145.html