0

我有此代码用于我正在制作的论坛的弹出系统,但该代码不适用于谷歌浏览器,但它适用于移动 safari。

document.getElementById('test').innerHTML="JAVASCRIPT IS FULLY FUNCTIONAL";
var w=window.innerWidth;
var h=Math.ceil(window.innerHeight/19);
var popup=new Kinetic.Stage({container:'notification',height:h,width:w});
var pla=new Kinetic.Layer();
var box=new Kinetic.Rect({x:0,y:0,width:w,height:h,fill:'#646362'});
pla.add(box);
avio=new Image();
avio.onload=function()
{
  var avi=new Kinetic.Image({x:3,y:3,image:avio,width:40,height:40});
  pla.add(avi);
  alert('test');
  popup.add(pla);
}
avio.src="testavi.png";
4

1 回答 1

0

Works for me on Chrome27/Win7.

By any chance are you getting a security alert in Chrome Inspector--Could be CORS?

于 2013-07-11T00:28:26.163 回答