No more haunted posts
04
Do you know those comments who seem pretty normal first but then grow odd when you come closer? Such as for example:
Nice blog post. Very useful. ccaajsajshkjdhjsadjkomglookatmysiteztooooooo.
Well, I suppose you know them. Most of you surely submit them to greedy Akismet which will eat them up. That is just what I have been doing. During the last weeks, I noticed an increase of spam comments on old posts from 2006. Sometimes, there is even no mail notification of such comment and they stay where they are for weeks and months. Today I finally decided to put this to an end by adding a plugin that closes posts after a certain period of time.
Close Old Posts was written by Matt Mullenweg and simply closes comments of older posts. You can upload and activate the plugin the usual way. Then click on “Edit” on the right side of the plugin description and you will see the editable source code of the plugin. The piece of code below determines the number of days after that comments are automatically closed. In this example, comments are closed on all posts older than 21 days. Adjust the number to your preference, then save your changes.
$cop_days_old = 21; // close comments after this many days
Now nobody will be able to spam your past posts:-)
To conclude, (and this is definetely off topic), I announce the moving in of a new orchid to my house, the third one actually. It was given to me today by my mom and it is so beautiful. This weekend I hope to take some photos and upload them to Flickr.
Filed under: Daily notes, WordPress 4 Comments


