Hi micheal, thank you for your support.
It really works, But i encounter a small problem,
After that last post i need to put a link to 5 past posts.
i used get posts plugin to display that before.
I want that to display after this last post
And another problem
This post is not following the margins. Means it is aligned totally left.
And this is the code of my page.php file.
If you can help me, it would be very useful.
<?php get_header(); ?>
<div class="art-contentLayout">
<div class="art-content">
<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
<div class="art-Post">
<div class="art-Post-body">
<div class="art-Post-inner art-article">
<h2 class="art-PostHeader">
<a href="<?php the_permalink() ?>" rel="bookmark" title="<?php printf(__('Permanent Link to %s', 'kubrick'), the_title_attribute('echo=0')); ?>">
<?php the_title(); ?>
</a>
</h2>
<div class="art-PostContent">
<?php if (is_search()) the_excerpt(); else the_content(__('Read the rest of this entry »', 'kubrick')); ?>
<?php if (is_page() or is_single()) wp_link_pages(array('before' => '<p><strong>Pages:</strong> ', 'after' => '</p>', 'next_or_number' => 'number')); ?>
</div>
<div class="cleared"></div>
</div>
<div class="cleared"></div>
</div>
</div>
<?php
$args=array(
'post_type' => 'post',
'post_status' => 'publish',
'posts_per_page' => 1,
'caller_get_posts'=> 1
);
$my_query = null;
$my_query = new WP_Query($args);
if( $my_query->have_posts() ) {
while ($my_query->have_posts()) : $my_query->the_post(); ?>
<p><a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></p>
<?php
the_content();
endwhile;
}
wp_reset_query(); // Restore global post data stomped by the_post().
?>
<?php comments_template(); ?>
<?php endwhile; endif; ?>
</div>
</div>
<div class="cleared"></div>
<?php get_footer(); ?>