WordPress : Restrict Comment changes to Admin and creator for 24 hours

Wordpress allows the “creator” of the post to edit anyone’s comment on that post (citation needed). And if the user has admin rights he can edit anyone’s comments. A requirement came across where I needed to limit the users to only edit their comments. I did not want them to play around with words of others on their posts. Also I did not want them to go back and edit their old comments (so they do not create unnecessary confusions for everyone). Here is a quick and dirty change that can limit the user’s capability on what they can do to comments. This shall be put in a plugin which will be the next thing I will take on. Continue reading “WordPress : Restrict Comment changes to Admin and creator for 24 hours”