這裏是我的小提琴:http://jsfiddle.net/mikeritter/prsfM/28/隱藏本文不上撥動留了
這裏是我的jQuery:
$(document).ready(function(){
function howdy(n){
alert('Howdy '+n+'!');
}
function hideArts(){
$('article').hide();
}
hideArts();
$("a.toggleart").click(function(){
var cur = $(this).parent().index();
//alert(cur);
$('article').eq(cur).toggle();
});
});
爲什麼文章立刻消失後切換?
由於下面的傢伙,但湯姆發現我的錯誤。其中一個「Doh!」時刻。 – mike