欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

js 打開新頁(yè)面在屏幕中間的實(shí)現(xiàn)方法

 更新時(shí)間:2016年11月02日 08:46:16   投稿:jingxian  
下面小編就為大家?guī)?lái)一篇js 打開新頁(yè)面在屏幕中間的實(shí)現(xiàn)方法。小編覺得挺不錯(cuò)的,現(xiàn)在就分享給大家,也給大家做個(gè)參考。一起跟隨小編過來(lái)看看吧
<a href="javascript:void(0)" onclick="window.open('http://www.dbjr.com.cn', 'newwindow', 'height=500, width=900, top='+Math.round((window.screen.height)/2<span style="font-family: Arial, Helvetica, sans-serif;">-250</span><span style="font-family: Arial, Helvetica, sans-serif;">)+',left='+Math.round((window.screen.width)/2</span><span style="font-family: Arial, Helvetica, sans-serif;">-450</span><span style="font-family: Arial, Helvetica, sans-serif;">)+',toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, status=no')">同意交換</a></span> 
</pre><pre code_snippet_id="1613432" snippet_file_name="blog_20160317_3_5070514" name="code" class="html"> 
<pre name="code" class="html"><script> 
function openwin(){ 
var width=Math.round((window.screen.width)/2<span style="font-family: Arial, Helvetica, sans-serif;">-400</span>); 
var height=Math.round((window.screen.height)/2<span style="font-family: Arial, Helvetica, sans-serif;">-200</span><span style="font-family: Arial, Helvetica, sans-serif;">);</span> 
window.open('http://www.dbjr.com.cn', 'newwindow', 'height=200, width=400, top='+height+',left='+width+',toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, status=no') 
} 
</script> 
<a href="javascript:void(0)" onclick="openwin();">同意交換</a> 
<div id="cnblogs_post_body"><pre class="best-text mb-10">===================各項(xiàng)參數(shù)============ 

其中yes/no也可使用1/0;pixel value為具體的數(shù)值,單位象素。

參數(shù) 取值范圍 說(shuō)明
alwaysLowered yes/no 指定窗口隱藏在所有窗口之后
alwaysRaised yes/no 指定窗口懸浮在所有窗口之上
depended yes/no 是否和父窗口同時(shí)關(guān)閉
directories yes/no Nav2和3的目錄欄是否可見
height pixel value 窗口高度
hotkeys yes/no 在沒菜單欄的窗口中設(shè)安全退出熱鍵
innerHeight pixel value 窗口中文檔的像素高度
innerWidth pixel value 窗口中文檔的像素寬度
location yes/no 位置欄是否可見
menubar yes/no 菜單欄是否可見
outerHeight pixel value 設(shè)定窗口(包括裝飾邊框)的像素高度
outerWidth pixel value 設(shè)定窗口(包括裝飾邊框)的像素寬度
resizable yes/no 窗口大小是否可調(diào)整
screenX pixel value 窗口距屏幕左邊界的像素長(zhǎng)度
screenY pixel value 窗口距屏幕上邊界的像素長(zhǎng)度
scrollbars yes/no 窗口是否可有滾動(dòng)欄
titlebar yes/no 窗口題目欄是否可見
toolbar yes/no 窗口工具欄是否可見
Width pixel value 窗口的像素寬度
z-look yes/no 窗口被激活后是否浮在其它窗口之上

以上就是小編為大家?guī)?lái)的js 打開新頁(yè)面在屏幕中間的實(shí)現(xiàn)方法全部?jī)?nèi)容了,希望大家多多支持腳本之家~

相關(guān)文章

最新評(píng)論