Duplicated title
-
Hi. With last WordPress and Anspress update the page titles shows duplacatedly… For first, WordPress showing page title, then Anspress showing same title. Worked fine in last WP and AnsPress version.
-
Yes for that you have to edit the page template and simply remove title.
For some reason I need to show title from anspress page template.So simply create a page template for anspress and do not add title there.
Thanks for answer. Unfortunately I’m not a php guru and my theme is handling whole content part in one piece, so I can’t edit that. :\
<?php /** * Template Name: Anspress * * A custom page template without sidebar. * * The "Template Name:" bit above allows this to be selectable * from a dropdown menu on the edit page screen. * * @package Cryout Creations * @subpackage tempera * @since tempera 0.5 */ get_header(); ?> <section id="container" class="one-column"> <div id="content" role="main"> <?php cryout_before_content_hook(); ?> <?php get_template_part( 'content/content', 'page'); ?> </div><!-- #content --> </section><!-- #container --> <?php get_footer(); ?>tell me the id of your AnsPress base page.
Create a file in your active wordpress theme with this name:
page-[base-page].php
replace [base-page] with anspress base page id.then paste this:
<?php get_header(); ?> <section id="container" class="one-column"> <div id="content" role="main"> <?php the_content(); ?> </div><!-- #content --> </section><!-- #container --> <?php get_footer(); ?>done, enjoy.
I really don’t know what i did now, but it’s working fine! I appreciate your kindness, and thanks a lot
Here is a copy of my template. How to do I get rid of the double title?
<?php
/* Detail page ofr – Pages */
get_header(); ?><div id=”content”>
<div id=”inner-content” class=”row clearfix”>
<div id=”main” class=”large-9 medium-12 columns” role=”main”>
<?php if ( current_theme_supports( ‘breadcrumb-trail’ )) breadcrumb_trail( array( ‘separator’ => ‘»’ ) ); ?>
<?php if (have_posts()) :
while(have_posts()): the_post();?>
<article id=”post-<?php $post->ID; ?>” <?php post_class(“clearfix”); ?> role=”article” itemscope itemtype=”http://schema.org/BlogPosting”><header class=”article-header clearfix”>
<h1 class=”page-title”><?php the_title(); ?></h1>
</header> <!– end article header –><section class=”entry-content clearfix” itemprop=”articleBody”>
<?php the_content(); ?></section> <!– end article section –>
<footer class=”article-footer”>
<p class=”clearfix”><?php the_tags(“<span class=\’tags\’>” . __(“Tags:”, “templatic”) . “</span> “, “, “, “”); ?></p>
</footer> <!– end article footer –></article> <!– end article –>
<?php comments_template(); ?>
<?php endwhile;
else : ?><?php get_template_part( ‘partials/content’, ‘missing’ ); ?>
<?php endif; ?>
</div> <!– end #main –>
<?php get_sidebar(); ?>
</div> <!– end #inner-content –>
</div> <!– end #content –>
<?php get_footer(); ?>
just remove this:
<header class="article-header clearfix"> <h1 class="page-title"><?php the_title(); ?></h1> </header> <!-- end article header -->Thanks a lot, it worked perfectly.
Its not working for me
I made template with name here in http://share-ask.com/wp-content/themes/Route/page-questions.php
& below is my template code
<?php
get_header(); ?>
<section id=”container” class=”one-column”>
<div id=”content” role=”main”>
<?php the_content(); ?>
</div><!– #content –>
</section><!– #container –>
<?php get_footer(); ?>
still same Double title error reply asap
The topic ‘Duplicated title’ is closed to new replies.