任何想法,为什么这不工作在我的PHP文档? 当我在jsfiddle上测试这个时,一切正常。为什么我的事件处理程序绑定与jQuery不发射?
<head>
<script type="text/javascript" src="http://code.jquery.com/jquery-1.7.1.min.js"></script>
<script type="text/javascript">
$("a").click(function() {
$("div.info").hide();
$("div." + this.className).show();
});
</script>
</head>
<body>
<div class="shipping-container">
<a href="#" class="ups">Show UPS info</a>
<a href="#" class="fedex">Show Fedex info</a>
<div class="ups info" style="display:none">the info for ups</div>
<div class="fedex info" style="display:none">Who let the dogs out</div>
</div>
</body>
不错的问题标题。 – Jules 2012-01-09 14:58:16
@Jules:不敢相信[没有人使用过标题](http://meta.stackexchange.com/questions/104914/add-title-uniqueness-to-the-heuristics-for-detecting-low-质量问题/ 106796#106796)! – Matt 2012-01-09 15:00:17
@Matt你的头衔比我做的好得多;) – 2012-01-09 15:01:36