Advertisement
dariotoby

comments.php

Aug 20th, 2022
34
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.15 KB | None | 0 0
  1. <?php
  2. /**
  3. * The template for displaying Comments.
  4. * The area of the page that contains both current comments
  5. * and the comment form.
  6. * If the current post is protected by a password and
  7. * the visitor has not yet entered the password we will
  8. * return early without loading the comments.
  9. *
  10. * @package zerif-lite
  11. */
  12.  
  13. if ( post_password_required() ) {
  14. return;
  15. }
  16. ?>
  17.  
  18. <div id="comments" class="comments-area">
  19.  
  20. <?php if ( have_comments() ) { ?>
  21.  
  22. <h2 class="comments-title">
  23.  
  24. <?php
  25. $comments_number = get_comments_number();
  26. if ( 1 === $comments_number ) {
  27. /* translators: %s: post title */
  28. printf( _x( 'Un commento su questo post.', 'comments title', 'zerif-lite' ), get_the_title() );
  29. } else {
  30. printf(
  31. /* translators: 1: number of comments, 2: post title */
  32. _nx(
  33. '%1$s commento su questo post.',
  34. '%1$s commenti su questo post.',
  35. $comments_number,
  36. 'comments title',
  37. 'zerif-lite'
  38. ),
  39. number_format_i18n( $comments_number ),
  40. '<span>' . get_the_title() . '</span>'
  41. );
  42. }
  43. ?>
  44.  
  45. </h2>
  46.  
  47. <?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) { ?>
  48.  
  49. <nav id="comment-nav-above" class="comment-navigation">
  50.  
  51. <h2 class="screen-reader-text"><?php _e( 'Leggi i commenti', 'zerif-lite' ); ?></h2>
  52.  
  53. <div class="nav-previous"><?php previous_comments_link( __( '&larr; Commenti precedenti', 'zerif-lite' ) ); ?></div>
  54.  
  55. <div class="nav-next"><?php next_comments_link( __( 'Commenti più recenti &rarr;', 'zerif-lite' ) ); ?></div>
  56.  
  57. </nav><!-- #comment-nav-above -->
  58.  
  59. <?php } ?>
  60.  
  61. <ul class="commentlist">
  62. <?php wp_list_comments( 'type=comment&callback=mytheme_comment' ); ?>
  63. </ul>
  64.  
  65. <?php if ( get_comment_pages_count() > 1 && get_option( 'page_comments' ) ) { ?>
  66.  
  67. <nav id="comment-nav-below" class="comment-navigation">
  68.  
  69. <h2 class="screen-reader-text"><?php _e( 'Leggi i commenti', 'zerif-lite' ); ?></h2>
  70.  
  71. <div class="nav-previous"><?php previous_comments_link( __( '&larr; Commenti precedenti', 'zerif-lite' ) ); ?></div>
  72.  
  73. <div class="nav-next"><?php next_comments_link( __( 'Commenti più recenti &rarr;', 'zerif-lite' ) ); ?></div>
  74.  
  75. </nav><!-- #comment-nav-below -->
  76.  
  77. <?php } ?>
  78.  
  79. <?php } ?>
  80.  
  81. <?php
  82.  
  83. // If comments are closed and there are comments, let's leave a little note, shall we?
  84. if ( ! comments_open() && '0' != get_comments_number() && post_type_supports( get_post_type(), 'comments' ) ) :
  85. ?>
  86. <p class="no-comments"><?php _e( 'Il post è chiuso.', 'zerif-lite' ); ?></p>
  87.  
  88. <?php endif; ?>
  89.  
  90. <?php
  91. comment_form(
  92. array(
  93. 'comment_notes_after' => '',
  94. )
  95. );
  96. ?>
  97.  
  98. </div><!-- #comments -->
  99.  
  100. <style>
  101. ul.commentlist li {
  102. margin-bottom: 50px !important;
  103. clear: both !important;
  104. }
  105. a.comment-reply-link.button.button--small.button--white, a.comment-reply-link.button.button--small.button--white:hover {
  106. border-color: transparent !important;
  107. position: relative !important;
  108. display: block !important;
  109. float: left;
  110. background: transparent !important;
  111. color: #fff;
  112. text-transform: capitalize;
  113. border-radius: 0px;
  114. transition: none !important;
  115. -webkit-transition: none !important;
  116. -moz-transition: none !important;
  117. -ms-transition: none !important;
  118. -o-transition: none !important;
  119. height: auto !important;
  120. width: 100%;
  121. padding: 0px;
  122. line-height: 20px;
  123. margin: 0 auto;
  124. padding: 0px;
  125. max-width: 200px;
  126. text-align: left;
  127. font-weight: 600;
  128. font-size: 13px !important;
  129. }
  130. .newcomment1, .newcomment2, .newcomment3, .newcomment4 {
  131. display: block !important;
  132. width: 100% !important;
  133. clear: both !important;
  134. position: relative !important;
  135. }
  136. .comment-meta.commentmetadata.newcomment3, .comment-meta.commentmetadata.newcomment3 a {
  137. font-size: 13px !important;
  138. }
  139. cite.fn {
  140. font-size: 18px !important;
  141. font-weight: bold !important;
  142. margin-left: 40px;
  143. }
  144. span.says {
  145. font-size: 16px;
  146. margin-left: 10px;
  147. }
  148. .testocommento p {
  149. margin: 0 auto !important;
  150. padding: 5px !important;
  151. font-size: 22px !important;
  152. }
  153. </style>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement