window 中的其它对象
1.location
location=url; 重定向
location.href=url; 重定向
location.replace(url); 用新页面替代当前页面(不成后退到之前页面)
location.reload(true); 重新加载
需要记住的方法:
location.reload(true); 重新加载
location=url; 重定向
其它重定向方法:
window.navigate(url);
header(url);
<meta http-equiv="refresh" content="3"> 每三秒刷新一次页面
<meta http-equiv="refresh" content="3;url=http://baidu.com"> 三秒知道定向到其它页面
2.history
history.back(); 返回到上一个页面
history.go(-2); 后退两个页面
3.screen
屏幕可用高/宽度=显示器像素高/宽度-状态栏高/宽度
4.clipboardData
clipboardData.setData(content) 向剪贴板加入内容
1.location
location=url; 重定向
location.href=url; 重定向
location.replace(url); 用新页面替代当前页面(不成后退到之前页面)
location.reload(true); 重新加载
需要记住的方法:
location.reload(true); 重新加载
location=url; 重定向
其它重定向方法:
window.navigate(url);
header(url);
<meta http-equiv="refresh" content="3"> 每三秒刷新一次页面
<meta http-equiv="refresh" content="3;url=http://baidu.com"> 三秒知道定向到其它页面
2.history
history.back(); 返回到上一个页面
history.go(-2); 后退两个页面
3.screen
<Script>
with (document) {
write ("您的屏幕显示设定值如下:<P>");
write ("屏幕可用高度为screen.availHeight, "<BR>");
write ("屏幕可用宽度为", screen.availWidth, "<BR>");
write ("屏幕的色盘深度为", screen.colorDepth, "<BR>");
write ("显示器像素高度为", screen.height, "<BR>");
write ("显示器像素宽度为", screen.width);
}
</Script>
屏幕可用高/宽度=显示器像素高/宽度-状态栏高/宽度
4.clipboardData
clipboardData.setData(content) 向剪贴板加入内容