日期:2014-05-17 浏览次数:20759 次
var iTop = (window.screen.availHeight-30-iHeight)/2; //获得窗口的垂直位置;
var iLeft = (window.screen.availWidth-10-iWidth)/2; //获得窗口的水平位置;
//window.open(url,"",'height='+iHeight+',,innerHeight='+iHeight+',width='+iWidth+',innerWidth='+iWidth+',top='+iTop+',left='+iLeft+',toolbar=no,menubar=no,scrollbars=auto,resizeable=yes,location=no,status=yes');
window.showModalDialog(url,"",'dialogHeight='+iHeight+'px;dialogWidth='+iWidth+'px;dialogLeft='+iLeft+'px;dialogTop='+iTop+'px;status=no;resizable=no;scroll=yes');
<select id="sel2" class="select_m">
<option selected="selected">请选择</option>
<option>是</option>
<option>否</option>
</select>