Note that there are some explanatory texts on larger screens.

plurals
  1. POI am trying to get my date and comment count to be included in the loop
    primarykey
    data
    text
    <p>I am creating my first ever wordpress theme(and first time really using wordpress).</p> <p>I am trying to get my date and comment count to be included in the loop even though I have it on the left in a sidebar and I can't figure out how to include it.</p> <p><strong>Here is my code for the post (it includes the date, comment count, and post in that order with the post being part of the loop only currently) :</strong></p> <p>(I am using the 960 grid so you may see grid classes below)</p> <pre><code>&lt;div class="date_banner"&gt; &lt;div class="d"&gt;&lt;!-- sidebar 1 --&gt;&lt;?php the_time('d'); ?&gt;&lt;/div&gt; &lt;div class="m"&gt;&lt;!-- sidebar 1 --&gt;&lt;?php the_time('M'); ?&gt;&lt;/div&gt; &lt;div class="y"&gt;&lt;!-- sidebar 1 --&gt;&lt;?php the_time('Y'); ?&gt;&lt;/div&gt; &lt;/div&gt; &lt;div class="commentsnumber"&gt; &lt;?php comments_number('No comment', '1 comment', '% comments'); ?&gt; &lt;/div&gt; &lt;/div&gt; &lt;div class="grid_10"&gt; &lt;?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?&gt; &lt;!-- post --&gt; &lt;div class="post"&gt; &lt;div class="titlepostauthorimage"&gt; &lt;div class="post-title"&gt; &lt;a href="&lt;?php the_permalink(); ?&gt;"&gt;&lt;?php the_title(); ?&gt;&lt;/a&gt; &lt;/div&gt; &lt;div class="post-author-image"&gt; &lt;/div&gt; &lt;div class="post-author"&gt; &lt;?php the_author_posts_link(); ?&gt; &lt;/div&gt; &lt;div class="post-image"&gt; &lt;?php the_post_thumbnail( $size, $attr ); ?&gt; &lt;/div&gt; &lt;/div&gt; &lt;div class="post-bodyborder"&gt; &lt;div class="post-body"&gt; &lt;?php the_content(); ?&gt; &lt;/div&gt; &lt;/div&gt; &lt;div class="post-metaborder"&gt; &lt;div class="post-meta"&gt; &lt;?php the_category(', '); ?&gt; &lt;!-- post tags --&gt; &lt;/div&gt; &lt;/div&gt; &lt;div class="post-comments"&gt; &lt;?php wp_list_comments( $args ); ?&gt; &lt;/div&gt; &lt;/div&gt; &lt;!-- post --&gt; &lt;?php endwhile; else: ?&gt; &lt;!-- In case no posts were found --&gt; &lt;h1&gt;Hmmm? Cam't. Find. Post.&lt;/h1&gt; &lt;?php endif; ?&gt; </code></pre> <hr> <p>Here is what happens when I move the loop to above the date in the code in a test:<img src="https://i.stack.imgur.com/eH2ij.png" alt="test"></p> <p>the inspector says that in the first grid_10 class the date and comment count are below the post: <img src="https://i.stack.imgur.com/BtrXI.png" alt="inspector"></p> <hr> <p>Here is what my finished theme is supposed to look like and you can check out my work in progress at <a href="http://benlevywebdesign.com/wordpress/" rel="nofollow noreferrer">http://benlevywebdesign.com/wordpress/</a> (only the post is in the loop, the screen shots from above were a test/example of what happens when I just move the loop code)</p> <p><img src="https://i.stack.imgur.com/onLpC.png" alt="theme design"></p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload