<html>
<head>
<SCRIPT LANGUAGE="JavaScript">
<!-- begin
// please help yourself to this code.
var startTime =null;
var timerID =null;
var initial =new Date();
var pos =0;
var menuItem =null; function initArray() {
this.length = initArray.arguments.length
for (var i = 0; i < this.length; i++) {
this[i+1] = initArray.arguments[i]
}
} function parsemenuItem(data,num) {
for(var i=0;i<data.length;i++) {
if(data.substring(i,i+1)=="|") break;
}
if (num==0) return(data.substring(0,i));
else return(data.substring(i+1,data.length));
} function startTimer() {
initial = new Date();
startTime=initial.getTime();
stopTimer();
menuItem = new initArray("赛迪网Windows世界|http://www.ccidnet.com/school/system/",
"赛迪网冲浪指南针|http://www.ccidnet.com/school/net/",
"赛迪网软件下载园|http://www.ccidnet.com/school/soft/",
"赛迪网办公自动化|http://www.ccidnet.com/school/office/",
"赛迪网软件e学堂|http://www.ccidnet.com/school/software/",
"赛迪网多媒体之家|http://www.ccidnet.com/school/multimedia/",
"赛迪网培训与考试|http://www.ccidnet.com/school/exam/",
"赛迪网电脑大词典|http://www.ccidnet.com/school/dict/"
);
showTimer();
} function stopTimer() {
timerID=null;
menuItem=null;
//clearTimeout(timerID);
} function showTimer() {
pos= (pos == menuItem.length) ? 1 : pos + 1;
document.forms[0].elements[0].
value=parsemenuItem(menuItem[pos],0); timerID=window.setTimeout('showTimer()',4000);
} function goToUrl() {
//parent.welcome.location=parsemenuItem(menuItem[pos],1);
this.location=parsemenuItem(menuItem[pos],1);
return (false);
}
// end -->
</SCRIPT></head>
<body bgcolor="#ffffff" onLoad="window.startTimer()">
<FORM>
<INPUT TYPE="button" VALUE=" zhouqing " NAME="goTo"
onClick="window.goToUrl()">
</FORM>
</body>
</html>
程序运行后,提示“对象不支持这个属性或方法”,怎么回事,有哪个人知道,谢谢
<head>
<SCRIPT LANGUAGE="JavaScript">
<!-- begin
// please help yourself to this code.
var startTime =null;
var timerID =null;
var initial =new Date();
var pos =0;
var menuItem =null; function initArray() {
this.length = initArray.arguments.length
for (var i = 0; i < this.length; i++) {
this[i+1] = initArray.arguments[i]
}
} function parsemenuItem(data,num) {
for(var i=0;i<data.length;i++) {
if(data.substring(i,i+1)=="|") break;
}
if (num==0) return(data.substring(0,i));
else return(data.substring(i+1,data.length));
} function startTimer() {
initial = new Date();
startTime=initial.getTime();
stopTimer();
menuItem = new initArray("赛迪网Windows世界|http://www.ccidnet.com/school/system/",
"赛迪网冲浪指南针|http://www.ccidnet.com/school/net/",
"赛迪网软件下载园|http://www.ccidnet.com/school/soft/",
"赛迪网办公自动化|http://www.ccidnet.com/school/office/",
"赛迪网软件e学堂|http://www.ccidnet.com/school/software/",
"赛迪网多媒体之家|http://www.ccidnet.com/school/multimedia/",
"赛迪网培训与考试|http://www.ccidnet.com/school/exam/",
"赛迪网电脑大词典|http://www.ccidnet.com/school/dict/"
);
showTimer();
} function stopTimer() {
timerID=null;
menuItem=null;
//clearTimeout(timerID);
} function showTimer() {
pos= (pos == menuItem.length) ? 1 : pos + 1;
document.forms[0].elements[0].
value=parsemenuItem(menuItem[pos],0); timerID=window.setTimeout('showTimer()',4000);
} function goToUrl() {
//parent.welcome.location=parsemenuItem(menuItem[pos],1);
this.location=parsemenuItem(menuItem[pos],1);
return (false);
}
// end -->
</SCRIPT></head>
<body bgcolor="#ffffff" onLoad="window.startTimer()">
<FORM>
<INPUT TYPE="button" VALUE=" zhouqing " NAME="goTo"
onClick="window.goToUrl()">
</FORM>
</body>
</html>
程序运行后,提示“对象不支持这个属性或方法”,怎么回事,有哪个人知道,谢谢
解决方案 »
- z-index 在 IE 里无法完全发挥作用,问题出在哪里呢?
- javascript或者 ext能够产生GUID吗?
- 改梅花雪的树出现问题。求助!
- js绑定动态参数的方法
- [原创] 一个多级联动js代码,js面像对象方式编写,WEB开发你一定能够用到!
- 高人指教 JavaScript 如何读取 XML连接数据库字符串 ??????
- 看看这样写 有问题吗? 转向用的
- js操作iframe的问题 急急急
- 呵呵,高手进来,遇到一变态问题(涉及采用XmlHttpRequest进行局部刷新后调用onload等函数的问题)
- JAVASCRIPT在有的计算机上好用,有的计算机上就不好用,为什么啊?
- jquery 读取xml问题
- 请问一个javascript跳转页面传参数的问题
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<SCRIPT LANGUAGE="JavaScript">
<!--begin
// please help yourself to this code.
var startTime = null;
var timerID = null;
var initial = new Date();
var pos = 0;
var menuItem = null;function initArray() {
this.length = initArray.arguments.length
for (var i = 0; i < this.length; i++) {
this[i + 1] = initArray.arguments[i]
}
}function parsemenuItem(data, num) {
for (var i = 0; i < data.length; i++) {
if (data.substring(i, i + 1) == "|") break;
}
if (num == 0) return (data.substring(0, i));
else return (data.substring(i + 1,data.length));
}function startTimer() {
initial = new Date();
startTime = initial.getTime();
stopTimer();
menuItem = new initArray("赛迪网Windows世界|http://www.ccidnet.com/school/system/", "赛迪网冲浪指南针|http://www.ccidnet.com/school/net/", "赛迪网软件下载园|http://www.ccidnet.com/school/soft/","赛迪网办公自动化|http://www.ccidnet.com/school/office/", "赛迪网软件e学堂|http://www.ccidnet.com/school/software/", "赛迪网多媒体之家|http://www.ccidnet.com/school/multimedia/", "赛迪网培训与考试|http://www.ccidnet.com/school/exam/", "赛迪网电脑大词典|http://www.ccidnet.com/school/dict/");
showTimer();
}
function stopTimer() {
timerID = null;
menuItem = null;
//clearTimeout(timerID);
}
function showTimer() {
pos = (pos == menuItem.length) ? 1 : pos + 1;
document.forms[0].elements[0].value = parsemenuItem(menuItem[pos], 0); timerID = window.setTimeout('showTimer()',4000);
}
function goToUrl() {
//parent.welcome.location=parsemenuItem(menuItem[pos],1);
this.location = parsemenuItem(menuItem[pos],1);
return (false);
}
// end -->
</SCRIPT></head>
<body bgcolor="#ffffff" onLoad="window.startTimer()">
<FORM>
<INPUT TYPE="button" VALUE=" zhouqing " NAME="goTo" onClick="window.goToUrl()">
</FORM>
</body>
</html>