Unix timestamp for post comment
Use: global $comment; $timestamp = strtotime(“{$comment->comment_date_gmt} GMT”); Regards.
Use: global $comment; $timestamp = strtotime(“{$comment->comment_date_gmt} GMT”); Regards.
I wrote up this quick plugin that updates all posts of type post to comment_status open on activation, it should work for you. you can immediately deactivate and delete it once you activate it that once. <?php /* Plugin Name: update comment status */ function activate_update_comment_status() { global $wpdb; $wpdb->update( $wpdb->posts, array( ‘comment_status’ => ‘open’ … Read more
There is no need for a plugin. The reason people get this confused is because posts can have comments enabled or disabled on an individual basis. There is no “global” option, because it’s per post. So really, it just takes two main steps to disable comments in WordPress: Settings > Discussion. Turn off both “Allow … Read more
The code below should be something similar to what you’re looking for Inside the loop template you use for listing blogs (like index.php) you need something like this <a href=”<?php the_permalink(); ?>/#respond”> <!– The blog permalink with the anchor ID after –> <i class=”fa fa-comments-o”></i> Leave a Comment </a> Inside your comments.php file you could … Read more
The comments_template hook: add_filter( ‘comments_template’, function ( $template ) { return ‘/absolute/path/to/your/comments.php’; });
My suggestion would be twofold: Ensure you are properly enqueueing the comment-reply script Replace your hard-coded comment list with wp_list_comments() Enqueueing comment-reply I would recommend hooking into comment_form_before(): function wpse71451_enqueue_comment_reply() { if ( get_option( ‘thread_comments’ ) ) { wp_enqueue_script( ‘comment-reply’ ); } } // Hook into comment_form_before add_action( ‘comment_form_before’, ‘wpse71451_enqueue_comment_reply’ ); Outputting the comment list … Read more
Can you please try this php function html_entity_decode(get_the_content());. I have used this function on php to remove html tags, you can try this.
You can do that simple by using plugin User Role Editor. It is very easy to use.
Community Moderation Plugin for Comments [closed]
Display posts with comments closed, with pagination?