打开页面就是全屏的方法
类别: JavaScript教程
<script language="javaScript">
function intro()
{
if ((navigator.appVersion.indexOf("Mac")!=-1) &&
(navigator.userAgent.indexOf("MSIE")!=-1) &&
(parseInt(navigator.appVersion)=4))
{
skip()
}
else
{
popup()
}
}
function skip()
{
location.href="http://yourdomain/index.htm";
}
function popup()
{
version =parseFloat(navigator.appVersion.substring(navigator.appVersion.indexOf(\'.\')-1,navigator.appVersion.length));
if (version >=4)
version = parseFloat(navigator.appVersion.substring(navigator.appVersion.indexOf(\'.\')-1,navigator.appVersion.length));
if (version >= 4)
{
if (navigator.appName=="Netscape")
{
Hello = window.open("http://yourdomain/index.htm","Hello","scrollbars");
Hello.focus();
}
if (navigator.appName=="Microsoft Internet Explorer")
{
window.open("http://
yourdomaintg/index.htm","screen","fullscreen==yes");
}
}
else
{
location.href="http://ypurdomain/index.htm";
}
}
</script>
<BODY onload=intro()>
</BODY></HTML>
function intro()
{
if ((navigator.appVersion.indexOf("Mac")!=-1) &&
(navigator.userAgent.indexOf("MSIE")!=-1) &&
(parseInt(navigator.appVersion)=4))
{
skip()
}
else
{
popup()
}
}
function skip()
{
location.href="http://yourdomain/index.htm";
}
function popup()
{
version =parseFloat(navigator.appVersion.substring(navigator.appVersion.indexOf(\'.\')-1,navigator.appVersion.length));
if (version >=4)
version = parseFloat(navigator.appVersion.substring(navigator.appVersion.indexOf(\'.\')-1,navigator.appVersion.length));
if (version >= 4)
{
if (navigator.appName=="Netscape")
{
Hello = window.open("http://yourdomain/index.htm","Hello","scrollbars");
Hello.focus();
}
if (navigator.appName=="Microsoft Internet Explorer")
{
window.open("http://
yourdomaintg/index.htm","screen","fullscreen==yes");
}
}
else
{
location.href="http://ypurdomain/index.htm";
}
}
</script>
<BODY onload=intro()>
</BODY></HTML>
- 上一篇: 源码学习:一个简单的日历控件
- 下一篇: 用JS绘图
-= 资 源 教 程 =-
文 章 搜 索