Here is one small security to protect your wordpress site.
We all know that, when the blog admin left a comment on his blog, WordPress use the name in the comment css class. If admin left a comment on his blog any would-be hacker/cracker only has to figure out your password–making it much easier to get into your site. So..
Remove admin name in comments class
Here’s simple solution, put this code on your functions.php
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
function remove_comment_author_class( $classes ) {
|
foreach( $classes as $key => $class ) { |
|
if(strstr($class, "comment-author-")) { |
|
unset( $classes[$key] ); |
|
} |
|
} |
|
return $classes; |
|
} |
|
add_filter( 'comment_class' , 'remove_comment_author_class' ); |
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The code above will clean comment_class for the author.
Thank You!







Of course, what a great site and informative posts, I will add backlink – bookmark this site? Regards, Reader
Hello, this is my first time i visit here. I found so many interesting in your blog especially on how to determine the topic. keep up the good work.
I REALLY liked your post and blog! It took me a minute bit to find your site…but I bookmarked it. Would you mind if I posted a link back to your post?
Interesting read, perhaps the best article iv’e browse today. We learn everyday cheers to you!
Thanks for posting. Good to see that not everyone is using RSS feeds to build their blogs
I’ve been checking your blog for a while now, seems like everyday I learn something new
Thanks
Good! Thank you! I always wanted to write in my site something like that. Can I take part of your post to my blog?
I was just having a conversation over this I am glad I came across this it cleared some of the questions I had.