Post Format Infinite Loop
-
I’ve been stuck on this infinite loop since last night and can’t figure it out.
in my functions.php, I have:
// Add post formarts support: http://codex.ww.wp.xz.cn/Post_Formats add_theme_support('post-formats', array('aside', 'gallery', 'link', 'image', 'quote', 'status', 'video', 'audio', 'chat')); add_post_type_support( 'news', 'post-formats', array( 'gallery', 'image' ) ); add_post_type_support( 'recipies', 'post-formats', array( 'video', 'aside', 'link' ) ); }then I have a content.php file with:
<?php /** * The default template for displaying content. Used for both single and index/archive/search. * * @subpackage FoundationPress * @since FoundationPress 1.0 */ ?> <article id="post-<?php the_ID(); ?>" <?php post_class(); ?>> <header> <h2><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h2> <?php FoundationPress_entry_meta(); ?> </header> <div class="entry-content"> <?php the_content(__('Continue reading...', 'FoundationPress')); ?> </div> <?php if( have_posts() ) : ?> <?php while( have_posts() ) : the_post(); ?> <?php get_template_part('content', get_post_format() ); ?> <?php endwhile ?> <?php else : ?> <?php get_template_part('content', 'none' ); ?> <?php endif; ?> <footer> <?php $tag = get_the_tags(); if (!$tag) { } else { ?><p><?php the_tags(); ?></p><?php } ?> </footer> <hr /> </article>I’ve experimented with having content-quote.php, content-video.php, etc… but i’m still getting an infinite loop. Any help is appreciated!
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
The topic ‘Post Format Infinite Loop’ is closed to new replies.