Some time back, we had seen how a Simple Fast Forward Button can show how much you respect your reader’s time. (get it here) Today, I just tweaked some code so as to say hello to first time commentators. No, this is not about those plugins that send an email when they comment, in fact this is not about any plugin.
Here is a screenshot of what the result will look like…

Usually, when a comment is held for moderation, you get the message ‘Your comment is awaiting moderation’. Well, this doesn’t help us much; some may not even understand what that mean. The idea is to edit that default message and display a friendly hello message as above.
Say Hello to First Time Commentators
The default text ‘Your comment is awaiting moderation’ is inside a file comment-template.php. We are going to edit this file, replace the text with our new message and tweak the position of the message so that it looks good. Follow the steps.
Find the file: the file comment-template.php is in the wp-includes folder of your WordPress installation.
Download it: Bring the file to your computer via your favorite FTP program.
Backup the file: Save a copy of the file securely. (Backups don’t mean that you are going to make errors, it’s just the part of a standard procedure.)
Find the text: Open comment-template.php in a text editor and search for ‘moderation’. You will end up with a line like this on line number 1229 if you haven’t edited the file before.
<em><?php _e('Your comment is awaiting moderation.') ?></em>
Write your message: Replace the text ‘Your comment is awaiting moderation’ with your own custom message. You can use the standard html here like line-breaks and italics. By default it takes the style from your style sheet. Make sure that the message is more general because at times comments from old commentators will also go into moderation. They might be annoyed to find you thanking them for their first comment.
Tweak the Code: If you save the file after the last step, the message will come after the name of the commentator as below.

So move the line you just edited to above the name of the commentator in the comment-template.php file . The final code will look like
[sourcecode language='php']
< id=”comment-“>
div id=”div-comment-“>
comment_approved == ’0′) : ?>
You May Also Like To Read:
- Remove Admin from Recent Comments List (No Plugin)
- Add Custom Status or Notes to a Post without a Plugin
- How To Create Short URL’s on your WordPress Domain without a Plugin or Script
- Add a Fast Forward Button to Respect Reader’s Time
- If you have 1000+ comments awaiting moderation, this is for you



%s says:‘), get_comment_author_link()) ?>
[/sourcecode]
Enable Comment Moderation: Go to your wordpress admin > Settings > Discussion and tick the box that reads ‘Comment author must have a previously approved comment’. By enabling this all the comments of first time commentators will be held in a moderation queue, even if it doesn’t contain any link or spammy content.
That’s it! Oh, if you don’t like to have the fun of editing the code yourself, just copy and paste the above code replacing the appropriate code in the file. If you have an editor like Notepad++ that shows you line numbers, then replace the code from lines 1220 to 1230 with the above code.
Wish to see a working demo? Try leaving a comment here!
Update: Kim raised an issue regarding this method. She pointed out that, when WordPress updates the core files (i.e. when we move from WordPress 2.7.1 to 2.7.2 and so on..) they might replace the comment-template.php file. So we will have to do it all over again. Though wordpress won’t be replacing the file with every update, we will have check if its working each time. So thats one limitation of this tweak. She have written a related article which the code lovers will enjoy reading. Check it out. Thanks Kim!