在打开的窗口中覆盖window.open属性

时间:2014-08-29 22:26:36

标签: javascript jquery

我有一个父页面,其中有一个链接可以打开一个带有滚动的新弹出窗口。 父代windiow中使用的代码是:

ebayShowPopupWindow(this.href, '', 472, 320, 'no', 'no', 'no', 'no', 'no');  

方法实施是:

function showPopupWindow(url, name, width, height, toolbar, location, status, scrollbars, resizable, menubar, left, top, customprops) {
    var props = "";
    if (width) props += ",width=" + width;
    if (height) props += ",height=" + height;
    if (toolbar) props += ",toolbar=" + toolbar;
    if (location) props += ",location=" + location;
    if (status) props += ",status=" + status;
    if (scrollbars) props += ",scrollbars=" + scrollbars;
    if (resizable) props += ",resizable=" + resizable;
    if (menubar) props += ",menubar=" + menubar;
    if (left) props += ",screenX=" + left + ",left=" + left;
    if (top) props += ",screenY=" + top + ",top=" + top;
    if (customprops) props += "," + customprops;
    if (props != "") props = props.substring(1);
    var w = window.open(url, name, props);
    if (!is.opera && w && !w.closed) w.focus();
    return w;
}

现在我的问题是:我们可以在子窗口的页面加载中覆盖窗口滚动属性吗?

原因:我们有不同团队使用的页面链接,他们限制弹出窗口中的滚动,该窗口隐藏了页面的某些部分。

我试图做一些不起作用的事情:

$(document).ready(function() {
    var b = $.browser;
    window.scrollbars = 'yes';
    window.scrollbars.visible= true;
});

0 个答案:

没有答案