My website is amandabloom.com.
I’m really digging Spun and having fun playing around with it. I’ve amended the front page to display pages instead of posts, and I gave also created a custom page template based on the index.php file to create a page for my “Blog” section, which will be a feed of all my posts categorized as “Blog.”
My goal in creating the custom template was to create a feed for specific posts and have it look exactly like the front page, lovely circles and all. I got the feed going, but my circles have gone all floppy! Another post with a featured image is a square. You can see what happened with this Blog page here: amandabloom.com/blog.
I’m probably missing something in my custom page template. I’ll copy it here. Any insight would be much appreciated! I’m planning on doing the same thing with another custom page template to create a “Portfolio” posts page.
<?php /** * Template Name: Blog Template * *A jerryrigged file for the Blog page pulled from Spun's main index file. * * @package Spun * @since Spun 1.0 */ get_header(); ?> <div id="primary" class="content-area"> <div id="content" class="site-content" role="main"> <?php if ( is_home() && ! is_paged() ) : ?> <h2 class="site-description"><?php bloginfo( 'description' ); ?></h2> <?php endif; ?> <?php if ( have_posts() ) : ?> <?php query_posts('post_category=blog'); ?> <?php /* Start the Loop */ ?> <?php while ( have_posts() ) : the_post(); ?> <?php /* Include the Post-Format-specific template for the content. * If you want to overload this in a child theme then include a file * called content-___.php (where ___ is the Post Format name) and that will be used instead. */ get_template_part( 'content', 'home' ); ?> <?php endwhile; ?> <?php spun_content_nav( 'nav-below' ); ?> <?php elseif ( current_user_can( 'edit_posts' ) ) : ?> <?php get_template_part( 'no-results', 'index' ); ?> <?php endif; ?> </div><!-- #content .site-content --> </div><!-- #primary .content-area --> <?php get_sidebar(); ?> <?php get_footer(); ?>
- The topic ‘Created a custom page for category posts, circles got sloppy!’ is closed to new replies.