Questions tagged [wp-list-comments]

Displays comments, for a post of a post type that supports comments, based on a variety of parameters including ones set in the administration area.

25 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
1
vote
0answers
61 views

Can't show most recent comment on top with wp_list_comments() for WooCommerce reviews

I am trying to break my comments (reviews) on my single product page into various pages, having the latest comments displayed on top of each pages and the latest comments displayed on the first page / ...
1
vote
0answers
868 views

Display date and time in comments

I use wp_list_comments(); to display a list of comment in WordPress. But it does show the format characters instead of the correct datetime. How can I fix this bug? Thank you.
1
vote
0answers
244 views

wp_list_comments renders incorrectly nested <ul>

I'm trying to figure out how wp_list_comments works. So I made the simplest possible callback just to see the structure of the result: function custom_comments_callback( $comment, $args, $depth ) { ...
1
vote
1answer
88 views

Customizing Comments on Posts

I have implemented custom code for generating comments on post page using callback function in functions.php. function MYTHEME_comment($comment, $args, $depth) { $GLOBALS['comment'] = $comment; ?&...
0
votes
0answers
10 views

Custom Comment Walker returns blank?

I posted this on normal Stack Overflow but thought perhaps it might do better here. I'm trying to create a custom comment walker for my theme because I want to change the way Wordpress outputs its ...
0
votes
0answers
19 views

Customize wp_list_comments() function to show part of the comment and put show more

Team. I have a comment section, some of the comments are long. Is there a way to customize the comment to show only 20 words and have a continue button to show the whole comment.
0
votes
0answers
61 views

WordPress Comments sort by custom meta key

I want to sort comments by a number of likes which is saved as a meta_key in the wp_commentmeta table: I have tried two ways but it doesn't sort the comments by most liked comment at the top. Please ...
0
votes
0answers
44 views

How to add delete, approve, spam Links to Comments

I am developing a plugin where I list all the available comments and then I want to have a links like Delete, Approve, Unapprove or Spam etc. I have followed a thread here: Add delete, approve, spam ...
0
votes
1answer
64 views

Disable Wordpress Comment Author Name

I am using the Wordpress theme Switty and was wondering how to entirely disable the comments section's poster. I need to create a member-only, anonymous comments section and am using Wishlist Member ...
0
votes
1answer
43 views

Removing(replacing) avtar in comments.php with some other HTML arrangements

<ol class="comment-list"> <?php wp_list_comments( array( 'style' => 'ol', 'short_ping' => true, ...
0
votes
1answer
96 views

edit-comments.php comment_row_actions ajax problem

On the edit-comments.php page, I'm hooking into the comment_row_actions filter to add another link at the end. I'm copying the "Approve" link, adding another query key and value and modifying the ...
0
votes
1answer
93 views

Show comments based on user role in front end

I want to allow commenting on a custom post type by a specific user role. And a user can see only his comments only. Scenario is e.g User roles are student and instructor. The Student can comment on ...
0
votes
1answer
51 views

How modify comments metabox on post edit screen in Wordpress?

I search a solution for custom the comment's html on post edit screen when i click to the button "add new comment". I want to add a ACF field in the form. The codex not explain a solution... Or an ...
0
votes
1answer
229 views

standard callback function for wp_list_comments

I know that the code for the comment is generated in Walker_Comment::comment() and for html5 themes in the method Walker_Comment::html5_comment. But if I try to copy the code from that last method ...
0
votes
1answer
735 views

How to get the 5 most recent comments and each comment 5 most recent replies (children)

I want to get the 5 most recent comments and each comment's 5 most recent replies (children) in descending order. With the following code I can get the 5 most recents comments but it won't distinguish ...
0
votes
1answer
533 views

Posting a comment redirects admin/users to blank page

I have looked a lot on this problem on forums and tried out a few of the solutions but nothing seems to work for me. When I try to comment here: http://www.chicitout.co.nf/crochet-lace-skater-dress/ ...
0
votes
2answers
143 views

How Can I display the Current Logged-In User's Comment at the Top of the Comments Section in Wordpress?

What I'm trying to do is show the current logged in user's comment at the top of the list in the comments section in Wordpress on any given post. I don't care if it is just duplicated at the top and ...
0
votes
1answer
91 views

Paginated Comments “reply” does not work!

I use plugin Paginated Comments. I edit template and CSS in paginated-comments.php but "reply" does not work. "reply" does not appear at all. http://i.imgur.com/ieIeadO.jpg (There should be a button ...
0
votes
0answers
79 views

Comments page id wp_list_comments

Under post i want to display last five comments. At next comment page or after click button "show more comments" I want to display all comments or set quantity comments to display. How can i do it? ...
0
votes
0answers
40 views

How to create a designated comment page with custom fields

I'm creating a site where I want to use the comment box to auto-generate a FAQ page. In essence, when a comment is posted it won't appear on the same page as the comment box. Instead, it will be ...
0
votes
0answers
136 views

Theme comment callback results nothing

I made theme and now im finally editing the look of wp_list_comments. I made function, wrote callback link to arguments and tried it. It returns nothing - only elements hard coded in comments.php are ...
0
votes
1answer
90 views

By Default, Turn Comments Off for Pages & Leave Comments On for Posts

By default "Discussion: Allow comments." is checked when a new page or post is created. I know you can make "Discussion: Allow comments." unchecked by default on both pages and posts by going to "...
0
votes
1answer
71 views

Comment Function

How would I make this Function display only the latest 5 comments? function showLatestComments() { global $wpdb; $sql = " SELECT DISTINCT comment_post_ID, comment_author, comment_date_gmt, ...
0
votes
2answers
145 views

wp_list_comments() only returns when user is loged in

<?php if (!is_user_logged_in()) { ?> <p class="text-center"> برای ارسال نظر باید <a href="https://www. .com/login?redirect_to=<?php echo the_permalink();?>"><i class="fa fa-...
-1
votes
1answer
90 views

wp_list_comments adds unnecessary elements

wp_list_comments adds UL / OL or DIV which do not serve for my thema. how do I prevent this?? screeshots: http://d.pr/i/1bpn my code http://pastebin.com/bQxUyZTs tnx!