title: Jquery Toggle in Wordpress
body: <p>I'am working on a Team member page in Wordpress. 
  This team member page should be automatically filled when new members are added. 
  I used the plugin CPT UI and this works great.</p>
  
  <p>The content is hidden so that only images are beeing seen on the team page. 
  Works fine. </p>
  
  <p>But now i want to toggle the hidden content when clicked on the image. </p>
  
  <p>What i have till this far works great for the first image, but when second image is clicked, the content of the first "image" toggles </p>
  
  <p>so i think i need some kind of loop for this? </p>
  
  <p>i'am a complete beginner with Jquery / javascript so i hope some one can help me out. </p>
  
  <pre><code> get_header(); ?&gt;
  
  
  &lt;div id="page-content-wrapper"&gt;
       &lt;div class="container-fluid"&gt;
          &lt;div class="row"&gt;
            &lt;div class="col-lg-12"&gt;
              &lt;a href="#menu-toggle" class="btn btn-default" id="menu-toggle"&gt;&lt;span class="glyphicon glyphicon-menu-hamburger"&gt; &lt;/span&gt;&lt;/a&gt;
  
      &lt;section id="team-images"&gt;                      
  
  
  
  &lt;?php $loop = new WP_Query( array ('post_type' =&gt; 'team' , 'orderby' =&gt; 'post_id' , 'order' =&gt; 'ASC') ); ?&gt;
  
  &lt;?php while ( $loop-&gt;have_posts() ) : $loop-&gt;the_post(); ?&gt; 
  
  
  &lt;div id="test-bob"&gt; 
  
  &lt;?php 
      if ( has_post_thumbnail() ) {
          the_post_thumbnail( array( 200 , 200 ) );
  }
  ?&gt;
  
  &lt;section id="team-data"&gt; 
  &lt;div class="container-fluid"&gt;
      &lt;div class="row"&gt;
          &lt;div class="col-sm-12"&gt; 
  &lt;?php the_title(); ?&gt; 
  &lt;?php the_content(); ?&gt;
  
  
  
  &lt;/div&gt;
  &lt;/div&gt;
  
  &lt;/div&gt; 
  
  
  &lt;/section&gt;
  
  &lt;/div&gt;
  
  &lt;?php endwhile; ?&gt;   
  
  
   &lt;script&gt;
      $("#test-bob").click(function() {
  
      $("#team-data").toggle("slow" , function() {
  
          // animation complete.
      });
  
  });
  
  
  
  &lt;/script&gt;  
      &lt;/section&gt;
  
  &lt;?php get_footer(); ?&gt;
  </code></pre>