誰かがこれで私を助けることができますか? それぞれの「showfaqanswer」をクリックすると「faqanswer」が表示されるようにしたいだけです。PHP と jQuery コードの何が問題なのかわかりません。助けてくれてありがとう!
<?php query_posts("cat=17&posts_per_page=7&offset=7"); ?>
<?php if ( have_posts() ) while ( have_posts() ) : the_post(); ?>
<p>
<a href="#" id="showfaqanswer"><?php the_title(); ?></a><br />
</p>
<div id="faqanswer"><?php the_content(); ?></div>
<?php endwhile; ?>
jQuery(document).ready(function() {
$('#showfaqanswer').click(function(){
$('#faqanswer').nextUntil('#showfaqanswer').show();
});
});