Advertisement
Guest User

Untitled

a guest
Mar 14th, 2012
48
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.52 KB | None | 0 0
  1. <?php
  2. // Do not delete these lines
  3. if (!empty($_SERVER['SCRIPT_FILENAME']) && 'comments.php' == basename($_SERVER['SCRIPT_FILENAME']))
  4. die ('Please do not load this page directly. Thanks!');
  5.  
  6. if ( post_password_required() ) { ?>
  7. <p class="nocomments">This post is password protected. Enter the password to view comments.</p>
  8. <?php
  9. return;
  10. }
  11. ?>
  12.  
  13. <!-- You can start editing here. -->
  14.  
  15. <?php if ( have_comments() ) : ?>
  16. <h3 id="comments"><?php comments_number('No Responses', 'One Response', '% Responses' );?> to &#8220;<?php the_title(); ?>&#8221;</h3>
  17.  
  18. <ol class="commentlist">
  19. <?php wp_list_comments(); ?>
  20. </ol>
  21.  
  22. <div class="breaker"></div>
  23. <?php else : // this is displayed if there are no comments so far ?>
  24.  
  25. <?php if ( comments_open() ) : ?>
  26. <!-- If comments are open, but there are no comments. -->
  27.  
  28. <?php else : // comments are closed ?>
  29. <!-- If comments are closed. -->
  30. <p class="nocomments">Comments are closed.</p>
  31.  
  32. <?php endif; ?>
  33. <?php endif; ?>
  34.  
  35.  
  36. <?php if ( comments_open() ) : ?>
  37.  
  38. <div id="respond">
  39.  
  40. <div class="cancel-comment-reply">
  41. <small><?php cancel_comment_reply_link(); ?></small>
  42. </div>
  43.  
  44. <?php if ( get_option('comment_registration') && !is_user_logged_in() ) : ?>
  45. <p>You must be <a href="<?php echo wp_login_url( get_permalink() ); ?>">logged in</a> to post a comment.</p>
  46. <?php else : ?>
  47.  
  48. <?php comment_form(); ?>
  49.  
  50. <?php endif; // If registration required and not logged in ?>
  51. </div>
  52.  
  53. <?php endif; // if you delete this the sky will fall on your head ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement