Sau*_*mar 1 javascript ajax jsp
我的jsp页面中有一个链接.
链接看起来像这样
<a href="javascript:doSomething('abc.ff' , 'abc.ff?m=1')">
Run Code Online (Sandbox Code Playgroud)
javascript代码
function doSomething(url, url_progress){
parent.win1.location.href = url;
/* Wait until something surely has started! */
window.setTimeout("this.startFinally()", 1000);
this.startFinally = function (){
location.href = url_progress;
}
}
Run Code Online (Sandbox Code Playgroud)
当用户碰到这个碰撞时,一切正常.最近我把这个代码放在一个iframe中然后没有任何反应.我检查了firebug并得到了这个错误:
Permission denied to access property 'win1'
[Break On This Error] parent.win1.location.href = url;
Run Code Online (Sandbox Code Playgroud)
可能是什么问题?