comment_reply_link not work with me

Question

I have this code that get me last comments in my site :

function bg_recent_comments($no_comments = 30, $comment_len = 80, $avatar_size = 48) {
                        $comments_query = new WP_Comment_Query();
                        $comments = $comments_query->query( array( 'number' => $no_comments , 'status' => 'approve') );
                        $comm = '';
                        if ( $comments ) : foreach ( $comments as $comment ) :
                            $comm .= '<li id="comment-160546">
                            <br><a href="'.get_permalink($comment->comment_post_ID).'" style="font-family:droid arabic kufi;text-align: center;font-style: italic;font-weight: bold;font-size: 15px;">'.get_the_title($comment->comment_post_ID).'</a><br><br>
                                <div class="comment byuser comment-author-hasan-ly odd alt thread-odd thread-alt depth-1 comment-wrap">
                                    <div class="comment-avatar">'.get_avatar( $comment->comment_author_email, $avatar_size ).'</div>
                                    <div class="comment-content">
                                        <div class="author-comment">
                                            <cite class="fn">'.get_comment_author( $comment->comment_ID ).'</cite>                  
                                            <div class="comment-meta commentmetadata"><a href="' . get_permalink( $comment->comment_post_ID ) . '#comment-' . $comment->comment_ID . '">Post URL</a></div><!-- .comment-meta .commentmetadata -->
                                            <div class="clear"></div>
                                        </div>
                                        <p>' . $comment->comment_content . '</p>
                                    </div>
                                </div><!-- #comment-##  --><br>
                            </li>';
                        endforeach; else :
                            $comm .= 'No comments.';
                        endif;
                        echo $comm; 
                    }

Now my problem is when add comment_reply_link to can any user replay to this comment. its now show the form reply,

When var_dump comment_reply_link its return me NULL.

How can solve it

--------------------------------------------------

>>> Share a link to this question, just copy and paste the code bellow on your web page <<<

<a href="https://www.wptricks.com/question/comment_reply_link-not-work-with-me/">

comment_reply_link not work with me</a>
0
user3507956 4 years 0 Answers 45 views 0

Leave an answer