2012-08-25 34 views
0

我想知道如何將瀏覽器設置爲當鏈接打開時自動最大化窗口屏幕?如何在鏈接打開時自動最大化窗口屏幕?

下面的示例代碼:

<a href="http://www.w3schools.com" target="_blank">Visit W3Schools</a> 

的事情之一是它總是打開一個小屏幕。我想要的是一個全屏幕的窗戶。我將JSP頁面用作前端。

回答

0

試試這個

<html> 
<head> 
<title></title> 
<script type="text/javascript"> 
function fullScreen(theURL) { 
window.open(theURL, '', 'fullscreen=yes, scrollbars=yes,location=yes,resizable=yes'); 
} 
</script> 
</head> 

<body> 
<a href="javascript:void(0);" onclick="fullScreen('http://www.w3schools.com');">Visit W3Schools</a> 
</body> 
</html> 
相關問題