+ -
当前位置:首页 → 问答吧 → 高手请进 BUG行38 错误:无效字符 出现了运行时间错误。是否进行调试?

高手请进 BUG行38 错误:无效字符 出现了运行时间错误。是否进行调试?

时间:2010-10-17

来源:互联网

<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
<style type="text/css">

#2 {
background-color: #000066;
height: 100px;
width: 100px;
display: none;
border: 1px dashed #000000;
}
#1 {
background-color: #FF0000;
height: 200px;
width: 200px;
border: 1px solid #000000;
}
.mune {
cursor: crosshair;
}
a:hover{ text-decoration:underline; color:#ff0000;}
</style>
</head>

<body>
<div id="1">红色
</div>
<div id="2">蓝色
</div>
<ul>
<li><a href="#"class="menu">红色</a></li>
<li><a href="#"class="menu">蓝色</a></li>
</ul>
<script language="JavaScript"src="jquery-1.3.2.min.js" type="text/javascript"> </script>
<script language="JavaScript" type="text/javascript"> //行38 错误:无效字符 出现了运行时间错误。是否进行调试?
$(document).ready(function(){ alert("完毕")});
var menu = $(".menu");
menu.eg(0).bind("click",function(){
  $("1").slidedown("slow");
$("2").slideup("slow")
});
menu.eg(1).bind("click",function(){
  $("2").slidedown("slow");
$("1").slideup("slow")
});

</script>
</body>
</html>

作者: su272009   发布时间: 2010-10-17

JScript code
$(document).ready(function(){ alert("完毕")});  //);//后面的括号和分号是中文状态的了。。。。。。改成英文状态的

    var menu = $(".menu");

//是eq,不是eg
menu.eq(0).bind("click",function(){
//大小写未区分而且ID选择器也未写对
  $("#1").slideDown("slow");
$("#2").slideUp("slow")
});

//是eq,不是eg
menu.eq(1).bind("click", function () {
//大小写未区分而且ID选择器也未写对

  $("#2").slideDown("slow");
$("#1").slideUp("slow")
})

作者: showbo   发布时间: 2010-10-18