我在点击H2后尝试切换以下链接的可见性但我不断碰到砖墙。
这是html和jquery
<div class="entry-content cibi">
<h2><strong>Corporate Infrastructure Service Plan</strong></h2>
<p><a href="http://intranet/cibi/files/2014/03/Service-Plan-including-Service-specific-risks-and-all-action-plans-.docx">Service Plan (including Service specific risks and all action plans)</a></p>
<p><a href="http://intranet/cibi/files/2014/03/Scorecard.pdf">Scorecard</a></p>
<p><a href="http://intranet/cibi/files/2014/03/Corporate-Infrastructure-Service-Plan.xls">Corporate Infrastructure Service Plan</a></p>
<h2><strong>Employee Statistics</strong></h2>
<p><a href="http://intranet/cibi/files/2014/03/Absence-Management-Statistics-.xls">Absence Management Statistics</a></p>
</div>
$(document).ready(function(){
$( "h2" ).click(function() {
$(this).nextuntil("h2").toggle()
return false;
});
});
有人可以帮忙吗?