How to show fullscreen popup window in javascript?

前端 未结 5 1755
被撕碎了的回忆
被撕碎了的回忆 2020-12-03 06:21

Is there a way to make a popup window maximised as soon as it is opened? If not that, at least make it screen-sized? This:

window.open(src, \'newWin\', \'ful         


        
5条回答
  •  -上瘾入骨i
    2020-12-03 07:17

    Use screen.availWidth and screen.availHeight to calculate a suitable size for the height and width parameters in window.open()

    Although this is likely to be close, it will not be maximised, nor accurate for everyone, especially if all the toolbars are shown.

提交回复
热议问题