Display custom text when comments are closed

If you go to comments.php in your theme – and search for “Comments are closed”, you should find it. You should also be able do this in functions.php: function comment_text ($arg) { $arg[‘title_reply’] = __(‘Too Late – Comments are Closed!’); return $arg; } add_filter(‘comment_form_defaults’,’comment_text’); Edit: Just noticed that you want this to work cross theme. … Read more

Customise Comment form

The default comment form fields are defined like so: $fields = array( ‘author’ => ‘<p class=”comment-form-author”><label for=”author”>’ . __( ‘Name’, ‘domainreference’ ) . ‘</label> ‘ . ( $req ? ‘<span class=”required”>*</span>’ : ” ) . ‘<input id=”author” name=”author” type=”text” value=”‘ . esc_attr( $commenter[‘comment_author’] ) . ‘” size=”30″‘ . $aria_req . ‘ /></p>’, ’email’ => ‘<p … Read more

Wrong IP address in comment section

I assume that by comment you actually mean a trackback/pingback. Those are sent from your server and not your computer and since in this case it sent from your server to itself it probably uses the local IP for the communication. 192.X.X.X is an IP range reserved for local in LAN communication same as the … Read more

What is the earliest hook comment meta can be saved?

If you look at the source for wp_new_comment() there is comment_post action hook, which fires immediately after comment is inserted into database and so is probably what fits your needs. However logically it’s after decision if comment is spam or not, I am not sure how meta is involved in your case since approval status … Read more

WordPress comment for virtual page

WordPress comments are segmented by IDs of their parent posts. For virtual pages you would either have to: replicate the process (by creating underlying Custom Post Type for it) or completely rebuild how it’s handled for them (for example by tracking segments as comment meta and query accordingly)

Copy and Paste Password for Comments

That is not a feature of WordPress. I have seen that particular wording before though. It is added by the “Spam Free WordPress” plugin. And yes, it’s not a great way to go. For spam prevention, I recommend using these plugins instead: Akismet Cookies for Comments Simple Trackback Validation

How to Define Custom Number of Items in Comment Feed

There’s a filter for that! The filter comment_feed_limit can be used to adjust the LIMIT clause directly. By default, the option from Settings -> Reading is used (“Syndication feeds show the most recent”), but that’s used for other feeds as well. The comment_feed_limit filter is used exclusively for comment feeds. add_filter( ‘comment_feed_limits’, ‘wpse150187_comment_feed_limits’ ); function … Read more