如何向右滚动弹出窗口

时间:2016-05-22 09:03:09

标签: javascript

我正在使用此功能在我的网站中打开弹出窗口。 我想向右滚动(它是RTL)窗口内容,但它不起作用:

popupWins[name].scrollRight += 1000;

有什么想法吗?

popupWins = new Array();

function windowOpener(url, name, args) {
/*******************************
the popupWins array stores an object reference for
each separate window that is called, based upon
the name attribute that is supplied as an argument
*******************************/
if ( typeof( popupWins[name] ) != "object" ){
popupWins[name] = window.open(url,name,args);
} else {
if (!popupWins[name].closed){
popupWins[name].location.href = url;
} else {
popupWins[name] = window.open(url, name,args);
}
}

popupWins[name].scrollRight += 1000;
popupWins[name].focus();


}

1 个答案:

答案 0 :(得分:0)

试试此代码

< meta http-equiv="Content-Security-Policy" content="default-src 'self' *.xyz.com data: gap: https://ssl.gstatic.com *.xyz.com 'unsafe-eval'; style-src 'self' 'unsafe-inline'; media-src *;connect-src *">