Results 1 to 5 of 5

Thread: Delete ALL Comments from Wordpress

  1. #1
    Will.Spencer's Avatar
    Will.Spencer is offline Retired
    Join Date
    Dec 2008
    Posts
    5,033
    Blog Entries
    1
    Thanks
    1,010
    Thanked 2,327 Times in 1,258 Posts

    Delete ALL Comments from Wordpress

    I noticed one of our Wordpress sites contained thousands of spam comments. These comments were all unapproved, so they were not published on the web site. Nevertheless, I decided to delete them.

    It would take an hour to delete all of those comments with the Wordpress GUI front-end, so I went to MySQL for a quick fix.
    SQL Command to Delete all Pending Comments In Wordpress:
    Code:
    delete from wp_comments WHERE comment_approved ="0";
    SQL Command to Delete all Approved Comments in Wordpress:
    Code:
    delete from wp_comments WHERE comment_approved ="1";
    SQL Command to Delete ALL Comments In Wordpress:
    Code:
    delete from wp_comments;
    As per usual, be certain to back up your database before using MySQL commands directly.
    Submit Your Webmaster Related Sites to the NB Directory
    I swear, by my life and my love of it, that I will never live for the sake of another man, nor ask another man to live for mine.

  2. Thanked by:

    Aquarezz (17 April, 2009)

  3. #2
    Aquarezz's Avatar
    Aquarezz is offline Master Net Builder
    Join Date
    Dec 2008
    Location
    Belgium
    Posts
    3,846
    Blog Entries
    4
    Thanks
    683
    Thanked 590 Times in 462 Posts
    Looks good, I didn't know we have a blog btw
    one of our Wordpress sites
    But I understand what you mean

    Thanks for the post
    |Nico Lawsons

  4. Thanked by:

    DomainMagnate (17 April, 2009)

  5. #3
    Will.Spencer's Avatar
    Will.Spencer is offline Retired
    Join Date
    Dec 2008
    Posts
    5,033
    Blog Entries
    1
    Thanks
    1,010
    Thanked 2,327 Times in 1,258 Posts
    Ahh... in this context, "our" meant "Free Internet Media."
    Submit Your Webmaster Related Sites to the NB Directory
    I swear, by my life and my love of it, that I will never live for the sake of another man, nor ask another man to live for mine.

  6. #4
    Aquarezz's Avatar
    Aquarezz is offline Master Net Builder
    Join Date
    Dec 2008
    Location
    Belgium
    Posts
    3,846
    Blog Entries
    4
    Thanks
    683
    Thanked 590 Times in 462 Posts
    Quote Originally Posted by Will.Spencer View Post
    Ahh... in this context, "our" meant "Free Internet Media."
    Yeah, that's why I added this to my comment:

    But I understand what you mean
    I didn't know it was related to FIM, but I knew it was related to you and your business
    |Nico Lawsons

  7. #5
    DomainMagnate's Avatar
    DomainMagnate is offline Super-Duper Moderator
    Join Date
    Dec 2008
    Posts
    749
    Blog Entries
    2
    Thanks
    150
    Thanked 175 Times in 110 Posts
    Nice! I think I've got a few blogs that need cleaning up

Similar Threads

  1. Wordpress Banning Links from Comments
    By 5starpix in forum Promoting
    Replies: 3
    Last Post: 16 February, 2010, 23:12 PM
  2. New domain for Wordpress and delete the old Cash
    By thesyndicate in forum Wordpress
    Replies: 5
    Last Post: 15 February, 2010, 11:53 AM
  3. [WTS] 500 WordPress Blog Comments for $5 (IN YOUR NICHE!)
    By stickycarrots in forum Links
    Replies: 52
    Last Post: 27 August, 2009, 21:33 PM
  4. WordPress Hack: Highlight Author Comments
    By Farrhad A in forum Wordpress
    Replies: 4
    Last Post: 15 June, 2009, 18:03 PM
  5. Delete ALL Comments from Drupal
    By Will.Spencer in forum Managing
    Replies: 0
    Last Post: 16 April, 2009, 09:02 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •