- This topic is empty.
-
AuthorPosts
-
August 24, 2013 at 1:57 pm #148041
Jon_N
ParticipantHey Guys,
When you navigate to a single blog post the post itself is repeating. I can’t figure out why.
Here’s the link: Blog
August 24, 2013 at 2:37 pm #148047TheDoc
MemberNeed to see the code for single.php. If there is a lot of stuff, create a private gist (https://gist.github.com/) and provide a link!
August 28, 2013 at 3:29 pm #148453Jon_N
ParticipantHey @TheDoc Here is my single.php
<?php
/**
* @package WordPress
* @since 1.0
*/wp_enqueue_style( ‘Oswald’, ‘http://fonts.googleapis.com/css?family=Oswald&v2’ );
$post_type = get_post_type();
if ( yiw_is_portfolio_post_type( $post_type ) ) {
get_template_part(‘single’, ‘portfolio’);
die;
}get_header() ?>
<div id="primary" class="layout-<?php echo yiw_layout_page() ?>"> <div class="inner group"> <?php if( get_post_meta( get_the_ID(), '_slogan_page', true ) ): ?> <div id="slogan"> <h1><?php echo get_post_meta( get_the_ID(), '_slogan_page', true ); ?></h1> <h3><?php echo get_post_meta( get_the_ID(), '_subslogan_page', true ); ?></h3> </div> <?php endif ?> <!-- START CONTENT --> <div id="content" class="group"> <?php $blog_type = yiw_get_option('blog_type'); ?> <?php switch( $post_type ) { default : get_template_part('loop', 'index'); } ?> </div> <!-- END CONTENT --> <!-- START LATEST NEWS --> <?php if( $post_type == 'bl_testimonials' ) { get_sidebar('testimonials'); } else { get_sidebar('blog'); } ?> <!-- END LATEST NEWS --> </div> </div>
August 28, 2013 at 5:36 pm #148455Senff
ParticipantLooks like the problem is not in single.php but in the loop. Can you post loop.php?
Not here on this forum but follow @TheDoc’s instructions.
August 28, 2013 at 10:24 pm #148464August 28, 2013 at 10:31 pm #148465Jon_N
ParticipantActually, I found the problem. This:
<?php if ( is_single() ) : ?> <div class="the-content"><?php the_content( str_replace( '->', '→', yiw_get_option('blog_read_more_text') ) ) ?></div> <?php wp_link_pages(); ?> <?php endif; ?>
Was in loop-blog-big.php twice. Thanks for taking a look guys @Senff and @TheDoc
-
AuthorPosts
- The forum ‘Back End’ is closed to new topics and replies.