reply comment below the comment box without reload page
reply comment below the comment box without reload page
reply comment below the comment box without reload page
How to show a list of comments on home page from all posts?
I also have a page where I list comments and replies to the current user comments. I might not be able to explain the answer very well, but this is what I did. I listed all the comments of the current user and listed again the comments with the parent_id of the current user’s comments. … Read more
Is it possible to give a classname to specific comments in the WordPress admin?
Not sure it’s the shortest way, but it works) Get post author id $post_author_id = get_post_field( ‘post_author’, $c->comment_post_ID ); Get author data by id $post_author_display_name = get_the_author_meta( ‘display_name’, $post_author_id ); Try this shorter version $output.= get_the_author_meta( ‘display_name’, get_post_field( ‘post_author’, $c->comment_post_ID ) ); Check documentation page which data is available with get_the_author_meta()
How do I make the comment disappear after deleting from the database?
It will be a three step process. You can use comment_form_logged_in_after (for logged in users) and/or comment_form_after_fields (for non-logged in users) actions to add your custom fields. Save the values as comment meta using update_comment_meta function hooked into comment_post action. Get the values using get_comment_meta. EDIT: 25-05-2022 Try this.. /* * This will add the … Read more
Why will comments not remain open on custom post types?
How do I restructure the comment HTML layout?
A little late, but you could also add the following to your theme’s functions.php file: /** Comment Form Function Defaults */ add_filter(‘comment_form_defaults’,’my_comment_defaults’); function my_comment_defaults($defaults) { global $user_identity, $id; if ( isset($post_id) ) $id = $post_id; else $post_id = $id; $commenter = wp_get_current_commenter(); $req = get_option( ‘require_name_email’ ); $aria_req = ( $req ? ” aria-required=’true'” : … Read more