Mark de Scande
Supreme Deity
Mind-Blowingly Helpful
Lifetime member
Member par excellence Likes (4)
Hey Guys
Do you want to clean up all the SPAM COMMENTS on a Multi Site ? if your answer is yes then read on !!
My Buddy here in South Africa Helped me with modding a cool plug.
1) http://wordpress.org/extend/plugins/wpcommentcleaner/
We will attach 2 zip files:
1) One DB WordPress MultiSite Setup
2) Multi DB / SharDB WordPress MultiSite Setup
All you have to do is pick the correct one and upload it to your /plugins folder and then edit it
WordPress MultiSite Setup (one db setup)
Use NotePad++ and edit WPCommentCleanerAdmin.php now to a find and replace
Look for exercise_wrdp1 and replace it with your DB name looking inside wp-config for your db name.
Now go to yoursite.com and go to wp-admin - plugins and activate please dont network activate it only have it active on the main site now on the bottom left look for CommentCleaner and go press delete easy :)
WordPress MultiSite Setup (Multi DB / Shar DB setup)
Use NotePad++ and edit WPCommentCleanerAdmin.php now to a find and replace
Look for blogline_home and replace it with your DB name looking inside wp-config for your db name. now look for blogline_ and replace all of them with your db prefex
Now go to yoursite.com and go to wp-admin - plugins and activate please dont network activate it only have it active on the main site now on the bottom left look for CommentCleaner and go press delete easy :)
I have just tested this on all my sites and it works.
If you guys love this them please go buy me a coffee
http://bloglines.co.za/fundraisers/support-bloglines-co-za/
Responses (24)
DEV Diva (joined February 2012) Likes (1)Liked by: 
Nice share, Mark (@Mark de Scande)!
Will download and keep it in my treasure trove of WordPress goodies... and will buy a coffee :)
Have a great day!
Gina
Member par excellence (joined May 2011) Likes (2)Liked by: 

@Gina B
LOL love coffee will attach this files now
I just used it to clear up 30K in spam comments on the http://www.bloglines.co.za just by clicking one button.
Just dont forget it is a modded version so it has bugs but it worked for me .
Member par excellence (joined May 2011) Likes (1)Liked by: 
The Files :)
1) http://bloglines.co.za/wpcommentcleanerMultiDB.zip
2) http://bloglines.co.za/wpcommentcleanerOneDB.zip
Support Kangaroo (joined March 2011) Likes (1)Liked by: 
Greetings Everyone,
The following attached files were contributed by Mark in which I am uploading them for him as he had asked me to.
Cheers, Joe
Member par excellence (joined May 2011) Likes (0)
@aecnu Thank you :)
DEV Diva (joined February 2012) Likes (2)Liked by: 

@masonjames
@Timothy
@Arun Basil Lal
@PC
@KimberlyL
Great share by @Mark de Scande :)
Have fun!
Member par excellence (joined May 2011) Likes (2)Liked by: 

Thank you time for my COFFEE :)
WPMUDEV-ian (joined November 2011) Likes (1)Liked by: 
Great Share Mark :)
Cheers
PC
Member par excellence (joined May 2011) Likes (0)
Hey guys small updates :)
The Files :)
1) http://bloglines.co.za/wpcommentcleanerMultiDB.zip
2) http://bloglines.co.za/wpcommentcleanerOneDB.zip
DEV Diva (joined February 2012) Likes (1)Liked by: 
Thank you for the update @Mark de Scande
Did you enjoy your coffee :)
Groetnis!
Gina
Member par excellence (joined May 2011) Likes (1)Liked by: 
nope no one used my coffee page
http://bloglines.co.za/fundraisers/support-bloglines-co-za/
Well at least i did some thing for Multi Site :)
Support Kangaroo (joined March 2011) Likes (1)Liked by: 
Greetings Mark,
Thank you for your contribution to the WPMU Dev community, it is appreciated Mark as you well know.
Cheers, Joe
Member (joined May 2012) Likes (0)
Congrats on a great plugin...just worked for me on one of my test projects...
glad to see another great South Africa team on board...are you CT or JHB based?
regards
Member par excellence (joined May 2011) Likes (0)
@DrTOK i am from Port Elizabeth :)
Ps we did some more mods to it but if it works for you then cool if you want just drop me a email mark@bloglines.co.za and i will send you the new files dont want to post them yet as i have not tested them 100% yet :)
Member (joined May 2012) Likes (1)Liked by: 
Thanks for the quick feedback Mark!
Am dropping you a mail now.
SO envious PE=Vinny Lingham, Shashi Naidoo, and now Mark :-D
chat soon!
Support Kangaroo (joined March 2011) Likes (1)Liked by: 
Greetings Mark,
It seems quite a few people are enjoying your contribution to the community.
Kudos to you sir!
Cheers, Joe
Member par excellence (joined May 2011) Likes (0)
Hey Guys
To use this with a big db set
1) SSH mysql set global max_connections = 100000;
2) PHP memory_limit 11198M / max_execution_time 13150 / max_input_time 13140
I have attach a screen shot for you to look at:
Member par excellence (joined May 2011) Likes (0)
Screen Shot
Member par excellence (joined May 2011) Likes (0)
Screen Shot After
Member (joined May 2010) Likes (1)Liked by: 
I wrote a script to address the comment spam issues after reading this a few months ago. The issue I was facing is simply that unlike most other users with a few WP or MU setups, I have hundreds of unique WP installs that may or may not use a consistent prefix, or might have BP or something else installed. I also discovered when writing this plugin that there's a bunch of extraneous data in another table (commentmeta - since WP2.9), which was wasted space after the comments were removed. Thus, to address each of these AND provide the ability to recover should some nutjob user actually tell me they intended to *keep* their archived spam (it happens), it creates a backup immediately before running. Nifty stuff, all free. Get it here:
http://12pd.com/s/wpcomments.zip
Read the comments in the file to see the specifics and requirements, but it should be pretty easy to configure for any linux-based VPS or dedicated server setup.
I run this once a week and purge the logs the following month. The first time I ran it, it purged 680k spam messages. Now I'm down to a mere couple thousand per week.
WPMUDEV-ian (joined November 2011) Likes (0)
Hey Shawn,
Nice to see you back :)
Thanks for the link.
Cheers, PC
Member par excellence (joined May 2011) Likes (0)
@Shawn Will test soon thank you.
Member (joined March 2009) Likes (0)
Have the files been removed?
http://bloglines.co.za/wpcommentcleanerOneDB.zip just seems to redirect to your homepage...
Member par excellence (joined May 2011) Likes (1)Liked by: 
@rmwb yes they have been
Ps This alsow works https://gist.github.com/Coopeh/4140391
Ps http://wpmu.org/daily-tip-how-to-mass-delete-comments-in-wordpress/
Ps http://wordpress.org/extend/plugins/wpcommentcleaner/
Ps http://wordpress.org/extend/plugins/mu-manage-comments-plugin/
Hope This helps
WordPress Questions?
We've got answers!
Find out more »