Advertisement
snugbabyshop

WP issue with previous/next links

Apr 12th, 2011
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.34 KB | None | 0 0
  1. For alchymyth:
  2.  
  3. Link to my site: http://www.snugbabyshop.co.uk/news/giving-birth-postpartum/how-to-breeze-through-babys-first-3-months/
  4.  
  5. Single.php:
  6.  
  7.  
  8. <?php get_header(); ?>
  9.  
  10. <?php include(TEMPLATEPATH."/left.php");?>
  11. <?php include(TEMPLATEPATH."/right.php");?>
  12.  
  13. <div id="content">
  14. <?php if (have_posts()) : while (have_posts()) : the_post(); ?>
  15.  
  16. <div class="post" id="post-<?php the_ID(); ?>">
  17. <div class="navigation">
  18. <div class="alignleft"><?php previous_post_link('&laquo; %link') ?></div>
  19. <div class="alignright"><?php next_post_link('%link &raquo;') ?></div>
  20. </div>
  21. <div class="clear"></div>
  22. <h1><a href="<?php echo get_permalink() ?>" rel="bookmark" title="Permanent Link:
  23. <?php the_title(); ?>"><?php the_title(); ?></a></h1>
  24.  
  25. <div class="entry">
  26. <?php the_content('<p>Continue reading &raquo;</p>'); ?>
  27.  
  28. <p class="postmetadata alt">
  29. <small>Posted: <?php the_time('m|j|y') ?> at <?php the_time() ?>.
  30. Filed under: <?php the_category(', ') ?>.
  31. <br /><?php the_tags('Tags: ', ', '); ?><br />
  32. New here? Follow this entry via <?php comments_rss_link('RSS 2.0'); ?>. <?php edit_post_link('[edit]'); ?>
  33.  
  34. <?php if (('open' == $post-> comment_status) && ('open' == $post->ping_status)) {
  35. // Both Comments and Pings are open ?>
  36. <a href="#respond">Comment</a> | <a href="<?php trackback_url(true); ?>" rel="trackback">Trackback</a>
  37.  
  38. <?php } elseif (!('open' == $post-> comment_status) && ('open' == $post->ping_status)) {
  39. // Only Pings are Open ?>
  40. Comments are closed, but you can <a href="<?php trackback_url(true); ?> " rel="trackback">trackback</a> from your own site.
  41.  
  42. <?php } elseif (('open' == $post-> comment_status) && !('open' == $post->ping_status)) {
  43. // Comments are open, Pings are not ?>
  44. Pinging is currently disabled.
  45.  
  46. <?php } elseif (!('open' == $post-> comment_status) && !('open' == $post->ping_status)) {
  47. // Neither Comments, nor Pings are open ?>
  48. Comments and pings are currently closed.
  49.  
  50. <?php } edit_post_link('Moderate','',''); ?>
  51. </small>
  52. </p>
  53.  
  54. </div>
  55. </div>
  56.  
  57. <div id="comments">
  58. <?php comments_template(); ?>
  59. </div>
  60. <?php endwhile; else: ?>
  61.  
  62. <p>Sorry, no posts matched your criteria.</p>
  63.  
  64. <?php endif; ?>
  65.  
  66. </div>
  67. <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement