升级到websphere 8后 - window.open无法正常工作 - 返回拒绝访问错误

时间:2013-07-18 11:51:49

标签: javascript websphere-6.1 websphere-8

首先,此代码在WAS 6.1环境中运行,但在迁移到WAS 8.0后却没有。正在使用的浏览器是IE8。是的我知道WAS是在后端,但看看改变了什么是主要的。

情景:

  • 用户登录主页
  • 然后打开另一个应用程序。用户做了一些工作
  • 然后专门调用此页面,该页面为其提供了一个返回主应用程序的链接。 window.open行win1 = window.open("", "mainFrame", "");现在提供拒绝访问错误。

任何想法?

function pageInit() {
    var aboutBlank = "true";
    var url = "";
    try{
        // get handle to existing open page
        win1 = window.open("", "mainFrame", "");
        alert("step 1 after window.open");
        // Check for the resetTab field.  If found, set it to Y 
        // do some stuff to the existing open page
        if (typeof win1.document.forms[0].resetTab != "undefined" 
            && win1.document.forms[0].resetTab != null) 
        {
            win1.document.forms[0].resetTab.value = 'Y';
        }
        win1.navigateToPage('<%=retrieveLink%>');
    }catch(ex){
        // If error is that object doesn't support property or method, then
        // user is probably not logged in.
        if (ex.description.indexOf("doesn't support this property or method") > -1)
        {
            alert("No current session available" + ex.description);
        } else {
            alert('An error occurred: ' + ex.description);
        }
    }
} // end of pageInit
close(); 
} 

0 个答案:

没有答案