Advertisement
gabyttvv

wordpress

Jan 13th, 2017
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.52 KB | None | 0 0
  1. <?php global $SMTheme; ?>
  2. <?php if ( post_password_required() ) { ?>
  3. <p><?php $SMTheme->_( ‘password’ ) ?></p>
  4. <?php return; } ?>
  5. <?php if ( $post->comment_status!=’open’ ) { ?>
  6. <p><?php $SMTheme->_( ‘closedcomments’ ) ?></p>
  7. <?php return; } ?>
  8.  
  9. <?php if ( have_comments() ) { ?>
  10. <div id=”comments”>
  11.  
  12. <h3 id=”comments-title”>
  13.  
  14. <?php
  15. if (get_comments_number()==1) {
  16. printf( $SMTheme->_( ‘formoneresponse’ ), ‘‘ . get_the_title() . ‘‘);
  17. } else {
  18. printf( $SMTheme->_( ‘formmultiresponse’ ), ‘‘ . get_the_title() . ‘‘, get_comments_number());
  19. }
  20.  
  21. ?></h3>
  22.  
  23. <ul class=”commentlist”>
  24. <?php wp_list_comments(‘callback=custom_comments’); ?>
  25.  
  26. <?php if ( get_comment_pages_count() > 1 ) { ?>
  27. <div class=”navigation clearfix”>
  28. <div class=”alignleft”><?php previous_comments_link( $SMTheme->_( ‘prevcomments’ ) ); ?></div>
  29. <div class=”alignright”><?php next_comments_link( $SMTheme->_( ‘nextcomments’ ) ); ?></div>
  30. </div><!– .navigation .clearfix –>
  31. <?php } ?>
  32.  
  33. </div><!– #comments –>
  34. <?php } ?>
  35.  
  36. <?php
  37. $args=array(
  38. ‘comment_field’ => ‘<p class=”comment-form-comment”><label for=”comment”>’ . $SMTheme->_( ‘comment’ ) . ‘</label><textarea id=”comment” name=”comment” cols=”45″ rows=”8″ aria-required=”true”></textarea></p>’,
  39. ‘must_log_in’ => ‘<p class=”must-log-in”>’ . sprintf( $SMTheme->_( ‘mustbe’ ).’ ‘.$SMTheme->_( ‘loggedin’ ).’ ‘.$SMTheme->_( ‘topostcomment’ ).’.’ , wp_login_url( apply_filters( ‘the_permalink’, get_permalink( $post->ID ) ) ) ) . ‘</p>’,
  40. ‘logged_in_as’ => ‘<p class=”logged-in-as”>’ . sprintf( __( $SMTheme->_( ‘loggedinas’ ).’ %2$s. ‘.$SMTheme->_( ‘logout’ ).’‘ ), admin_url( ‘profile.php’ ), $user_identity, wp_logout_url( apply_filters( ‘the_permalink’, get_permalink( $post->ID ) ) ) ) . ‘</p>’,
  41. ‘comment_notes_before’ => ‘<p class=”comment-notes”>’ . $SMTheme->_( ‘comment_notes_before’ ) . ‘</p>’,
  42. ‘comment_notes_after’ => ‘<p class=”form-allowed-tags”>’ . sprintf( $SMTheme->_( ‘comment_notes_after’ ), ‘ ' . allowed_tags() . '‘ ) . ‘</p>’,
  43. ‘id_form’ => ‘commentform’,
  44. ‘id_submit’ => ‘submit’,
  45. ‘title_reply’ => $SMTheme->_( ‘leavereply’ ),
  46. ‘title_reply_to’ => $SMTheme->_( ‘leavereply’ ),
  47. ‘cancel_reply_link’ => $SMTheme->_( ‘cancelreply’ ),
  48. ‘label_submit’ => $SMTheme->_( ‘addcomment’ )
  49. );
  50. comment_form($args);
  51. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement