Can someone advise where to comment out the page title in Coraline theme? I've tried different things and it does not work. Here's my page.php
有人可以建议在Coraline主题中注释掉页面标题的位置吗?我尝试了不同的东西,它不起作用。这是我的page.php
<div id="content-container">
<div id="content" role="main">
<?php if ( have_posts() ) while ( have_posts() ) : the_post(); ?>
<div id="post-<?php the_ID(); ?>" <?php post_class(); ?>>
<?php if ( is_front_page() ) { ?>
<h2 class="entry-title"><?php the_title(); ?></h2>
<?php } else { ?>
<h1 class="entry-title"><?php the_title(); ?></h1>
<?php } ?>
<div class="entry-content">
<?php the_content(); ?>
<?php wp_link_pages( array( 'before' => '<div class="page-link">' . __( 'Pages:', 'coraline' ), 'after' => '</div>' ) ); ?>
<?php edit_post_link( __( 'Edit', 'coraline' ), '<span class="edit-link">', '</span>' ); ?>
</div> <!-- .entry-content
</div> <!-- #post-## -->
<?php comments_template( '', true ); ?>
<?php endwhile; ?>
</div><!-- #content -->
</div><!-- #content-container -->
1 个解决方案
#1
0
I would assume it would be this line:
我认为这将是这一行:
<h1 class="entry-title"><?php the_title(); ?></h1>
To comment out, replace with:
要注释掉,请替换为:
<!--<h1 class="entry-title"><?php the_title(); ?></h1>-->
- >
You can also just leave the Title box empty when creating a new page in the admin panel.
您还可以在管理面板中创建新页面时将标题框留空。
#1
0
I would assume it would be this line:
我认为这将是这一行:
<h1 class="entry-title"><?php the_title(); ?></h1>
To comment out, replace with:
要注释掉,请替换为:
<!--<h1 class="entry-title"><?php the_title(); ?></h1>-->
- >
You can also just leave the Title box empty when creating a new page in the admin panel.
您还可以在管理面板中创建新页面时将标题框留空。