admin管理员组文章数量:1400621
window.open('branchMonitoring/', 'Testing Dual Monitor', 'resizable=1, scrollbars=1, fullscreen=0, height=200, width=650, screenX=0 , left=1280, toolbar=0, menubar=0, status=1');
I used this code to open a new window on second monitor but the new window still opens on first monitor and cannot exceed the first monitor's boundary. I tried to change "left" to a higher value but still no luck.
Please help me brothers. i am using latest google chrome browser and using windows 8 dual monitor.
Please do note that this solution works for me when using FireFox browser. But I need to get it work on chrome.
window.open('branchMonitoring/', 'Testing Dual Monitor', 'resizable=1, scrollbars=1, fullscreen=0, height=200, width=650, screenX=0 , left=1280, toolbar=0, menubar=0, status=1');
I used this code to open a new window on second monitor but the new window still opens on first monitor and cannot exceed the first monitor's boundary. I tried to change "left" to a higher value but still no luck.
Please help me brothers. i am using latest google chrome browser and using windows 8 dual monitor.
Please do note that this solution works for me when using FireFox browser. But I need to get it work on chrome.
Share Improve this question edited Feb 10, 2014 at 8:42 Alex Coroza asked Feb 10, 2014 at 8:23 Alex CorozaAlex Coroza 1,7573 gold badges23 silver badges39 bronze badges 5- 2 JavaScript cannot know where your second screen is located at though. – Derek 朕會功夫 Commented Feb 10, 2014 at 8:26
- possible duplicate of How do I get JavaScript to open a popup window on the current monitor – Volkan Ulukut Commented Feb 10, 2014 at 8:30
- @Derek朕會功夫 i think you can position the newly opened window by setting "left" attribute. but when I set it to 1280(my primary monitor's width) the window is still stucked at the first monitor. – Alex Coroza Commented Feb 10, 2014 at 8:37
- brothers i found some remedy on my prolem. – Alex Coroza Commented Feb 10, 2014 at 9:18
- see stackoverflow./a/57303963/1497139 how you can select a monitor with presentation-api in chrome and potentially other browsers. – Wolfgang Fahl Commented Aug 3, 2019 at 11:24
1 Answer
Reset to default 2After doing many researches, I found some remedy. Some are saying that this is a bug on chrome.
please refer too this link. https://stackoverflow./a/17972796/2276894
And also if you are targeting to create an admin/internal application, you can try Chrome App. It offers functions like, window.create()
with position parameters. You can control the position of the windows you created. Remember that you have to install the Chrome App you created in user's browser, just like in extensions.
本文标签: javascriptwindowopen on second monitorStack Overflow
版权声明:本文标题:javascript - window.open on second monitor - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744269663a2598120.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论