title: Set post classes to wordpress
body: <p>I have a small problem!</p>
  
  <p>I'm trying to add this code to my loop</p>
  
  <pre><code>&lt;?php post_class (); ?&gt;
  </code></pre>
  
  <p>in to this code:</p>
  
  <pre><code>    &lt;?php $ccfit_loop = new WP_Query( array( 'post_type' =&gt; 'photo', 'posts_per_page' =&gt; 9999 ) ); ?&gt;
  
          &lt;?php if ( $ccfit_loop-&gt;have_posts() ) : ?&gt;
              &lt;?php while ( $ccfit_loop-&gt;have_posts() ) : $ccfit_loop-&gt;the_post(); ?&gt;
                  &lt;?php
     $ccfit_img_big = wp_get_attachment_image_src( get_post_thumbnail_id( get_the_id() ), 'ccfit_big', false ); 
              echo '&lt;div id="blogpost" HERE SOULD THE CODE BE&gt;&lt;a href="'. get_permalink( $id ) .'"&gt;&lt;h2&gt;'. get_the_title() .'&lt;/h2&gt;&lt;/a&gt;&lt;img src="'. $ccfit_img_big[0] .'"&gt;&lt;/div&gt;';
                  ?&gt; 
              &lt;?php endwhile; ?&gt;
          &lt;?php endif; ?&gt;
  </code></pre>
  
  <p>Grateful for the quick reply!</p>