jQuery在MyEclipse中click事件不起作用

<!doctypehtml><htmllang="en"><head><metacharset="utf-8"><title>jQueryUIDialog-Animati... <!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>jQuery UI Dialog - Animation</title>
<link rel="stylesheet" href="WEB-INF/themes/base/jquery.ui.all.css">
<script src="WEB-INF/themes/jquery-1.10.2.js"></script>
<script src="WEB-INF/ui/jquery.ui.core.js"></script>
<script src="WEB-INF/ui/jquery.ui.widget.js"></script>
<script src="WEB-INF/ui/jquery.ui.mouse.js"></script>
<script src="WEB-INF/ui/jquery.ui.draggable.js"></script>
<script src="WEB-INF/ui/jquery.ui.position.js"></script>
<script src="WEB-INF/ui/jquery.ui.resizable.js"></script>
<script src="WEB-INF/ui/jquery.ui.button.js"></script>
<script src="WEB-INF/ui/jquery.ui.dialog.js"></script>
<script src="WEB-INF/ui/jquery.ui.effect.js"></script>
<script src="WEB-INF/ui/jquery.ui.effect-blind.js"></script>
<script src="WEB-INF/ui/jquery.ui.effect-explode.js"></script>
<link rel="stylesheet" href="demos.css">
<script>
$(function() {
$( "#dialog" ).dialog({
autoOpen: false,
show: {
effect: "blind",
duration: 1000
},
hide: {
effect: "explode",
duration: 1000
}
});

$( "#opener" ).click(function() {
$( "#dialog" ).dialog( "open" );
});
});
</script>
</head>
<body>

<div id="dialog" title="Basic dialog">
<p>This is an animated dialog which is useful for displaying information. The dialog window can be moved, resized and closed with the 'x' icon.</p>
</div>

<button id="opener">Open Dialog</button>

<div class="demo-description">
<p>Dialogs may be animated by specifying an effect for the show and/or hide properties. You must include the individual effects file for any effects you would like to use.</p>
</div>
</body>
</html>
展开
 我来答
匿名用户
2014-03-06
展开全部
你js的引用有问题,我把你的代码换几行就有效了

请参考
<link href="css/jquery-ui/jquery-ui.css" rel="stylesheet" />
<script src="js/jquery.js"></script>
<script src="js/jquery-ui.js"></script>

为什么你要把js放到WEB-INF下面?那样没法访问了
匿名用户
2014-03-06
展开全部
doctype 的问题
已赞过 已踩过<
你对这个回答的评价是?
评论 收起
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式