testing comments section
authorAnthony Talarico <talarico@gaslightmedia.com>
Fri, 8 Jan 2016 17:58:13 +0000 (12:58 -0500)
committerAnthony Talarico <talarico@gaslightmedia.com>
Fri, 8 Jan 2016 17:58:13 +0000 (12:58 -0500)
single.php

index 36a2ae9..3f82e44 100644 (file)
                                     </div><!--/#addthis_wrapper-->
                                     <?php } ?>
                                     <?php echo the_content(); ?>
-                                    <footer class="entry-meta small-12 medium-6 medium-push-3 center">
-                                        <?php $post_categories = wp_get_post_categories( get_the_ID() );
-                                        $cats = array();
-                                        echo 'This entry was posted ';
-                                        if (has_category()) {
-                                            echo 'in ';
-                                            foreach($post_categories as $c){
-                                                $cat = get_category( $c );
-                                                $cats[] = array( 'name' => $cat->name, 'slug' => $cat->slug );
-                                                echo '<a rel="category" title="View all posts in '. $cat->name . ' " href="'. $cat->slug .'">'. $cat->name .'</a>, ';
-                                            }
-                                        }
-                                        $post_tags = wp_get_post_tags( get_the_ID() );
-                                        $tags = array();
-                                        if (has_tag( )) {
-                                            echo ' and tagged ';
-                                            foreach($post_tags as $t){
-                                                $tag = get_tag( $t );
-                                                $tags[] = array( 'name' => $tag->name, 'slug' => $tag->slug );
-                                                echo '<a rel="category" title="View all posts in '. $tag->name . ' " href="'. $tag->slug .'">'. $tag->name .'</a>, ';
-                                            }
-                                        }
-                                        echo ' on ';
-                                        echo ' <span class="meta date"> ' . the_time('F jS, Y') . '</span>';
-                                        ?>
-                                    </footer>
                                 </article>
+                                <?php if ( comments_open() || get_comments_number() ) :
+                                comments_template();
+                                endif; ?>
                             </div>
                         </div>
                     </div>
                 </div>
-               <?php comments_template(); ?>
                 <?php endwhile; ?>
                 <?php else: ?>
                 <div id="post-404" class="noposts">