WP-Sweep

Beskrivning

This plugin cleans up:

  • Versioner
  • Auto drafts
  • Deleted comments
  • Unapproved comments
  • Spammed comments
  • Deleted comments
  • Orphaned post meta
  • Orphaned comment meta
  • Orphaned user meta
  • Orphaned term meta
  • Orphan term relationships
  • Unused terms
  • Duplicated post meta
  • Duplicated comment meta
  • Duplicated user meta
  • Duplicated term meta
  • Transient options
  • Optimizes database tables
  • oEmbed caches in post meta

This plugin uses proper WordPress delete functions as much as possible instead of running direct delete MySQL queries.

Following delete functions are used:

  • wp_delete_post_revision()
  • wp_delete_post()
  • wp_delete_comment()
  • delete_post_meta()
  • delete_comment_meta()
  • delete_user_meta()
  • delete_term_meta()
  • wp_remove_object_terms()
  • wp_delete_term()
  • delete_transient()
  • delete_site_transient()

WP-Sweep WP REST API Endpoints
* GET /wp-json/sweep/v1/count/<Name>. Get the number of items that we will be sweeping.
* GET /wp-json/sweep/v1/details/<Name>. Get the details of the items that we will be sweeping.
* DELETE /wp-json/sweep/v1/sweep/<Name>. Runs sweep for that particular item.

WP-Sweep WP-CLI Commands
* wp sweep --all. Runs sweep for all items.
* wp sweep <Name>. Runs sweep for that particular item.
* wp sweep <Name1> <Name2>. Run sweep for the selected items.

WP-Sweep Available Items:
* revisions
* auto_drafts
* deleted_posts
* unapproved_comments
* spam_comments
* deleted_comments
* transient_options
* orphan_postmeta
* orphan_commentmeta
* orphan_usermeta
* orphan_termmeta
* orphan_term_relationships
* unused_terms
* duplicated_postmeta
* duplicated_commentmeta
* duplicated_usermeta
* duplicated_termmeta
* optimize_database
* oembed_postmeta

WP-Sweep is not compatible with the following plugins:
* Asgaros Forum
* Custom Fonts
* Elementor Popup Builder
* MailPress
* Meta Slider
* Polylang
* Slider Revolution
* Viba Portfolio
* WPML

Build Status

Utveckling

Erkännande

Donationer

I spent most of my free time creating, updating, maintaining and supporting these plugins, if you really love my plugins and could spare me a couple of bucks, I will really appreciate it. If not feel free to use it without any obligations.

Skärmdumpar

  • WP-Sweep Administrator Page (Before Sweeping)
  • WP-Sweep Administrator Page (Swept)

Installation

  1. Upload wp-sweep folder to the /wp-content/plugins/ directory
  2. Activate the WP-Sweep plugin through the ’Plugins’ menu in WordPress
  3. You can access WP-Sweep via WP-Admin -> Tools -> Sweep

Vanliga frågor

Kommer snart …

Recensioner

11 februari 2022
How this plugin should work? I installed this plugin and my DB was 88.8 MB big. After install and Sweep All, my DB become 91.5 MB big, so maybe i just missed the point what the plugin does. I can change my review later if problem is on my side.
31 januari 2022
Elementor gave me Server Error 500. Their support suggested cleaning the revision table using this excellent plugin - and it did the trick 🙂 Only shame is that this plugin doesn't allow limiting the number of allowed revisions... for this you need another plugin or editing wp-config.php.
17 november 2021
Picked up stuff that the biggest plugins never did. It actually shaved a few ms off loading time (small but complex e-commerce site)
14 november 2021
I was a bit skeptical about this plugin just because I was a bit "afraid" to touch my database. Having absolutely NO knowledge of what is normal and what is not... my elementor plugin grew the post_meta database to 1399MB(!). I was tearing my hair out over the slow site until I found the database was the problem. Then I found the sweep plugin... three sweeps later (thousands of "revisions" and thousands of "duplicated post meta" and one sweep at the end to "optimize the tables") My elementor database size shrunk to 81MB (webshop with thousands of products and variations) and is running smoothly now. I had no problems with this at all. Thank you so much for this fantastic tool! There is one thing that could be improved -- but this really might be only because I had such a huge amount to sweep... the plugin page seemingly just stayed stuck on "sweeping..." I let it run for hours because I was afraid what would happen if I switch it off in the middle but eventually I did just refresh the page and it showed there was nothing left to sweep. So it might be nice to add some alert message that it finished or something similar.
25 oktober 2021
My new hero... WP Sweep after manually agonizing over my database trying to get rid of crapola, my wp_postmeta was 57MiB... for 26 pages... and I was sort of in agony Swept away 40 MB in just a couple minutes work thank you
Läs alla 110 betyg

Bidragsgivare och utvecklare

”WP-Sweep” är programvara med öppen källkod. Följande personer har bidragit till detta tillägg.

Bidragande personer

”WP-Sweep” har översatts till 16 språk. Tack till översättarna för deras bidrag.

Översätt ”WP-Sweep” till ditt språk.

Intresserad av programutveckling?

Läs programkoden, kika på SVN-filförvaret eller prenumerera på utvecklarloggen via RSS.

Ändringslogg

1.1.15

  • NEW: Bump to WordPress 5.8

1.1.4

  • FIXED: Replaced %_transient_% with %\_transient\_%. Escape _ in MySQL if not it is being used as a wildcard character. Props @janrenn.

1.1.3

  • FIXED: Changed permissions check to activate_plugins because update_plugins will return false when DISALLOW_FILE_MODS=true.

1.1.2

  • NEW: Changed permission check to update_plugins for better MultiSite compatibility.
  • NEW: Bump min PHP version to 5.6.

1.1.1

  • NEW: wp_sweep_excluded_termids filter.

1.1.0

  • NEW: Added WP Rest API Endpoint support, sweep/v1/count/<Name>, sweep/v1/details/<Name>, and sweep/v1/sweep/<Name>
  • FIXED: Follow as close as possible to WordPress Coding Standards

1.0.12

  • NEW: Bump to WordPress 4.9
  • NEW: Update README to incompatible plugins

1.0.10

  • FIXED: Invalid plugin head ’This plugin has an invalid header.’

1.0.9

  • NEW: Support for Codeclimate
  • FIXES: Uses get_sites() on WordPress 4.6. This should fix deprecated notices.
  • FIXES: Fixes translation placeholder count. Props @pedro-mendonca.
  • FIXES: Use manage_options capability as it conflicts with Admin Menu Editor on multisite installs. Props @EusebiuOprinoiu.

1.0.8

  • NEW: Added wp_sweep_excluded_taxonomies filter to allow more than just link_category taxonomy
  • NEW: Support for WP-CLI wp sweep

1.0.7

  • FIXES: Use custom query to delete Orphaned Term Relationship if wp_remove_object_terms() fails

1.0.6

  • NEW: Delete ’languages’ folder from the plugin
  • NEW: Use translate.wordpress.org to translate the plugin
  • FIXED: Works only with WordPress 4.4 because of new term meta

1.0.5

  • FIXED: apply_filters() wrong arguments

1.0.4

  • NEW: oEmbed caches in post meta Sweep
  • NEW: Add POT file for translators

1.0.3

  • NEW: AJAX Sweep All
  • NEW: AJAX Sweeping
  • NEW: View details of sweep
  • NEW: Optimize DB sweep
  • NEW: User hint and confirmation. Props @SiamKreative
  • FIXED: Division by zero. Pros @barisunver

1.0.2

  • FIXED: Use term_id for wp_remove_object_terms()
  • FIXED: number_format_i18n() issues after sweeping

1.0.1

  • NEW: Moved plugin location to WP-Admin -> Tools -> Sweep
  • NEW: Add Deleted Post Sweep
  • FIXED: Use forced_delete for wp_delete_post() and wp_delete_comment();
  • FIXED: If orphaned meta has an object id of 0, use SQL query to delete

1.0.0

  • Första utgåvan