;

页面如何让它不显示标题栏,菜单栏,工具栏,地址栏

<script>
opener=null; //在没有提示的状态下,关闭当前窗口
window.close();
var he=screen.availheight-75;
var wi=screen.availwidth-8;
window.open ("URL", "newwindow", "height="+he+",width="+wi+",=yes, toolbar=yes,scrollbars=yes,menubar=no, resizable=yes, location=no, status=yes,left=0,top=0")
</script>
页面如何让它不显示标题栏,菜单栏,工具栏,地址栏
:
<script language="javascript">
function SetOpenWindowChild(WinName){
var strWindowType="";
var newwin=null;
//directories=[yes|no|1|0] 指定是否出现链接工具栏.
strWindowType=strWindowType+"directories=no" + ",";
//channelmode=[yes|no|1|0] (IE4.0 only)为1时以'全屏模式'(相当于按F11)打开,并出现频道栏.
strWindowType=strWindowType+"channelmode=no" + ",";
//fullscreen=[yes|no|1|0] (IE4.0 only) 指定全屏模式打开,如果忘了放置关闭按钮,只好用ALT+F4了.
strWindowType=strWindowType+"fullscreen=no" + ",";

//height=number 指定窗口的高度(px),最小值为100px
strWindowType=strWindowType+"height=470" + ",";
//width=number 窗口的宽度(px),最小值为100px.
strWindowType=strWindowType+"width=630" + ",";
//left=number 指定窗口的左沿离开屏幕左沿的距离(px).
strWindowType=strWindowType+"left=150" + ",";
//top=number 指定窗口的上沿离开屏幕的距离(px).
strWindowType=strWindowType+"top=50" + ",";

//location=[yes|no|1|0] 指定是否出现地址栏.


strWindowType=strWindowType+"location=no" + ",";
//menubar=[yes|no|1|0] 指定是否出现菜单.
strWindowType=strWindowType+"menubar=no" + ",";
//resizable=[yes|no|1|0] 指定窗口是否可被改变大小.
strWindowType=strWindowType+"resizable=yes" + ",";
//scrollbars=[yes|no|1|0] 指定是否出现滚动条.
strWindowType=strWindowType+"scrollbars=yes" + ",";
//status=[yes|no|1|0] 指定是否出现状态栏
strWindowType=strWindowType+"status=no" + ",";
//toolbar=[yes|no|1|0] 指定是否出现工具栏 .
strWindowType=strWindowType+"toolbar=no" + ",";

//打开窗口
if (WinName=="null"){
newwin=window.open("","",strWindowType);

}
else{
window.open(WinName,"",strWindowType);

}
}
</script>


本人觉得这个方法不错,你可可以试一下,主要是用javascript来实现
你在后台进行这样的处理:
private void Page_Load(object sender, System.EventArgs e)
{
Page.RegisterStartupScript("ggg","<script>SetOpenWindowChild(WinName);</script>");
}
当然,你在前台已经写了我上面给你的javascript函数

window.open("Sample.htm",null,
"height=200,width=400,status=no,toolbar=no,menubar=no,location=no");
posted @ 2007-08-02 10:10  Ж╰ァ流星  阅读(2164)  评论(2编辑  收藏  举报