Results 1 to 8 of 8

Thread: Correct way to delete classipress ads with plugin

  1. #1
    Thread Starter
    scharpliving's Avatar
    Join Date
    Nov 2012
    Location
    United States
    Posts
    12
    Thanks
    2
    Thanked 2 Times in 2 Posts

    Correct way to delete classipress ads with plugin

    I am looking to make a plugin that will find ads marked as 'sold' or more technically in _postmeta where meta_key = cp_ad_sold and meta_value = yes. I can do the search no problem in MySQL, and use a join to use the post ID to delete related data out of other tables, but my question is, what tables have ad data in them? I want to delete ads "correctly"... I.E. delete their data from every table so there isn't junk data laying around in the tables.
    The following tables have ad data in them that I know of: cp_ad_geocodes, _posts, _post_meta. Are there any other tables that contain ad data that should be deleted when removing an ad?

    It's terrible having 'sold' ads sitting around on the site with no way to automatically prune them.

  2. #2
    samcy's Avatar
    Join Date
    Mar 2012
    Location
    Germany
    Posts
    12,098
    Thanks
    121
    Thanked 1,756 Times in 1,442 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!
    Rolf Hassel (Samcy)

  3. #3
    samcy's Avatar
    Join Date
    Mar 2012
    Location
    Germany
    Posts
    12,098
    Thanks
    121
    Thanked 1,756 Times in 1,442 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!
    Rolf Hassel (Samcy)

  4. #4
    nayyer's Avatar
    Join Date
    Oct 2012
    Location
    United Kingdom
    Posts
    135
    Thanks
    8
    Thanked 2 Times in 2 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!

  5. #5
    nayyer's Avatar
    Join Date
    Oct 2012
    Location
    United Kingdom
    Posts
    135
    Thanks
    8
    Thanked 2 Times in 2 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!

  6. #6
    samcy's Avatar
    Join Date
    Mar 2012
    Location
    Germany
    Posts
    12,098
    Thanks
    121
    Thanked 1,756 Times in 1,442 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!
    Rolf Hassel (Samcy)

  7. #7
    nayyer's Avatar
    Join Date
    Oct 2012
    Location
    United Kingdom
    Posts
    135
    Thanks
    8
    Thanked 2 Times in 2 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!

  8. #8
    cswebtech's Avatar
    Join Date
    Oct 2011
    Location
    United States
    Posts
    81
    Thanks
    5
    Thanked 0 Times in 0 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. How to correct breadcrumb trail in classipress?
    By harry0013 in forum Report ClassiPress Bugs
    Replies: 1
    Last Post: June 13th, 2012, 02:52 AM
  2. [MOD NEEDED] correct and align the images of the ads featured - ClassiPress 3.1.4
    By eberth in forum ClassiPress General Discussion
    Replies: 1
    Last Post: October 5th, 2011, 07:01 PM
  3. WP Custom search plugin working...but not 100% correct
    By mlanghorst in forum ClassiPress General Discussion
    Replies: 1
    Last Post: July 23rd, 2010, 03:27 PM