function stopScroll() {
if (arguments.length == 0) {
/*函数体*/
} else if (arguments.length == 1) {
/*函数体*/
}
}
var liObj = window.document.getElementsByTagName("li");
for (var i = 0; i < liObj.length; i++) {
var element = liObj;
element.onmouseover = function () {
stopScroll(i);
}
}
for (var i = 0; i < liObj.length; i++) {
var element = liObj;
element.index = i;
element.onmouseover = function () {
stopScroll(this.index);
}
}
欢迎光临 黑马程序员技术交流社区 (http://bbs.itheima.com/) | 黑马程序员IT技术论坛 X3.2 |