浏览代码

Merge pull request #3308 from Automattic/fix/3276-blank-canvas-comments-on-pages

Blank Canvas: Add support for comments on Pages
Kjell Reigstad 4 年之前
父节点
当前提交
6f264d2061
共有 1 个文件被更改,包括 7 次插入0 次删除
  1. 7 0
      blank-canvas/page.php

+ 7 - 0
blank-canvas/page.php

@@ -20,6 +20,13 @@ get_header();
 				the_post();
 				the_post();
 
 
 				get_template_part( 'template-parts/content/content-singular' );
 				get_template_part( 'template-parts/content/content-singular' );
+				
+				if ( true === get_theme_mod( 'show_comments', false ) ) :
+					// If comments are open or we have at least one comment, load up the comment template.
+					if ( comments_open() || get_comments_number() ) {
+						comments_template();
+					}
+				endif; 
 
 
 			endwhile; // End of the loop.
 			endwhile; // End of the loop.
 			?>
 			?>