I'd like to have my blog on a separate pare, and have the home page simply display the three most recent posts (along with my usual header, sidebar and whatnot).
I've set up a new page with a new page template, set it as a static homepage, and pasted in some code I found to display the posts. Now I'm having a devil of a time trying to paste in the style tags so the blog headers and content will display the same way as they do on the blog page! I also need to remove the page title, since it's styled the same way as my blog headers and will look weird.
Is there an easier way to accomplish this? Or, can someone help me figure out how to correctly insert my style tags?
My page, in half-styles disarray, is here: http://www.blogosaur.com/
And the page template code looks like this:
<?php /* Template Name: New Super Home
*/ ?>
<?php get_header(); ?>
<div class="content-bg">
<div class="main">
<div class="content-shadow">
<div class="column-one">
<?php if (have_posts()) : ?>
<?php while (have_posts()) : the_post(); ?>
<div class="blog-head">
<div class="blog-date"><?php the_time('d M Y') ?></div>
<div class="blog-header"><h2><a href="<?php the_permalink() ?>"><?php the_title(); ?></a></h2></div>
<div class="comment-icon"><?php comments_popup_link(0, 1, '%', '', ''); ?></div>
</div>
<div class="blog-main">
<div class="blog-content">
<?php the_content('(Continue Reading)'); ?>
<p class="date"><?php the_time('M dS') ?> by <?php the_author(); ?></p>
<p class="link"><a href="<?php the_permalink() ?>">Continue Reading</a></p>
<?php
$postslist = get_posts('numberposts=3&order=DESC&orderby=post_date');
foreach ($postslist as $post) :
setup_postdata($post);
?>
<li>
<a href="<?php the_permalink(); ?>"> </a> <p class="blog-head"> <?php the_title(); ?></p> <pclass="blog-content"<?php the_content(); ?></p>
<p class="date"><?php the_time('M dS') ?> by <?php the_author(); ?></p>
</li>
<?php endforeach; ?>
</div>
</div>
<?php endwhile; ?>
<?php else : ?>
<div class="blog-main">
<h2 class="not-found">Not Found</h2>
<p>Sorry, but you are looking for something that isn't here.</p>
</div>
<?php endif; ?>
<div class="paging-main">
<div class="page-count">Page 1 of 38</div>
<div class="page-list">
<ul class="paging">
<li><a href="#">1</a></li>
<li><a href="#">2</a></li>
<li><a href="#">3</a></li>
<li>.</li>
<li>.</li>
<li>.</li>
<li><a href="#">Last</a></li>
</ul>
</div>
</div>
</div>
<div class="column-two">
<?php get_sidebar(); ?>
</div>
</div>
</div>
</div>
<?php get_footer(); ?>