Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // comment function call on comment.php
- wp_list_comments(array(
- 'callback' => 'ration_comment_list'
- ));
- // wp comment list customazion function
- function ration_comment_list($comment, $args, $depth){
- $GLOBALS['comment'] = $comment;
- ?>
- <div id="comment-<?php comment_ID(); ?>" <?php comment_class('media single-comments'); ?>>
- <a class="mr-4" href="<?php echo esc_url($comment->comment_author_url); ?>">
- <?php echo get_avatar($comment, 80, '', '', array(
- 'class' => 'rounded-circle img-thumbnail',
- 'default' => get_option( 'avatar_default', 'retro' )
- )); ?>
- </a>
- <div class="media-body">
- <h5><a href="<?php echo esc_url($comment->comment_author_url); ?>"><?php echo esc_html($comment->comment_author); ?></a>
- <span class="time-ago-post"><?php comment_date('d F, Y'); ?> at <?php comment_time('g:i a'); ?></span>
- </h5>
- <p><?php echo esc_html($comment->comment_content); ?></p>
- <div class="mt-5">
- <?php
- comment_reply_link(
- array_merge($args, array(
- 'depth' => $depth,
- 'max_depth' => $args['max_depth'],
- 'reply_text' => __('<i class="icofont">reply</i> Reply', 'ration'),
- 'before' => '<ul class="likeunlikeBox mb-2"><li>',
- 'after' => '</li></ul>'
- ))
- );
- ?>
- </div>
- </div>
- </div><!-- end single comments -->
- <?php
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement