﻿=== Orphanix Media Cleanup ===
Contributors: limpu
Tags: media library, broken images, optimize images, images, media
Requires at least: 5.0
Tested up to: 6.9
Stable tag: 1.0.0
Requires PHP: 7.4
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Clean, optimize, and manage your WordPress media library by detecting unused, broken, and dynamically used media files.

== Description ==

**Orphanix Media Cleanup** is the all-in-one solution to clean, organize, and optimize your WordPress media library. It scans your site for unused, orphaned, broken, and dynamically loaded media files - including images, videos, and documents - so you can safely remove them and improve performance.

**Core Features:**
* **Media Scan:** Detect unused or orphaned media files in the library and uploads folder.
* **Broken Media Scan:** Identify missing, corrupted, or unreachable files that could break layouts or SEO.
* **Live Site Scan:** Analyze frontend usage to see which media is actually displayed to visitors.
* **Analytics:** Track scan summaries, usage trends, and storage impact.
* **Page Builder & Plugin Compatibility:** Works with Gutenberg, Elementor, ACF, WooCommerce, widgets, menus, and theme files (Deep Scan).
* **Safe Deletion Workflow:** Move files to trash before permanent deletion; delete all sizes & versions.
* **Bulk Actions & Filters:** Easily manage large media libraries with filters for unused, orphaned, or broken files.

**Benefits:**
* Free up storage space and reduce server load
* Prevent broken images and improve site reliability
* Keep media library organized and clean
* Ensure no live or builder-used media is accidentally deleted

**How it Works:**
1. Run a **Media Scan** to detect unused files.
2. Use **Broken Media Scan** to detect missing or corrupted files.
3. Perform a **Live Site Scan** to verify actual frontend usage.
4. Review **Analytics** for scan history and cleanup actions.
5. Delete safely using the built-in trash workflow - all file sizes and versions included.

**Why Orphanix Media Cleanup?**
It's designed for site owners, developers, and agencies who need a fast, safe, and comprehensive tool to keep WordPress media libraries clean, optimized, and error-free - all from one dashboard.

== Installation ==

1. Upload the `orphanix-media-cleanup` folder to the `/wp-content/plugins/` directory.
2. Activate the plugin through the **Plugins** menu in WordPress.
3. Navigate to **Orphanix** in the WordPress admin menu to start scanning your library.
4. Use the dashboard boxes to run scans and clean media safely.

== Frequently Asked Questions ==

= How is Media Scan different from Broken Media Scan? =
Media Scan finds unused or orphaned files. Broken Media Scan finds missing or corrupted files that are referenced but not present on your site.

= What does Live Site Scan do? =
Live Site Scan checks the actual frontend of your site to detect media that is dynamically loaded or used by page builders and plugins.

= Are deleted files recoverable? =
Yes. Files first go to a plugin-managed trash folder. You can restore them before permanent deletion.

= Does it delete all image sizes? =
Yes. When deleting a media file, all registered sizes and thumbnails are deleted along with the original file.

= Which page builders and plugins are supported? =
Gutenberg, Elementor, ACF, WooCommerce, widgets, navigation menus, and theme files (Deep Scan only).

== Screenshots ==

1. Dashboard overview with Media Scan, Broken Media Scan, Live Site Scan, and Analytics.
2. Media Scan Wizard with Regular and Deep scan steps.
3. Broken Media Scan results table.
4. Live Site Scan results and dynamic media usage detection.
5. Analytics summary showing scan history and results.

== Changelog ==

= 1.0.0 =
* Initial release with full Media Scan, Broken Media Scan, Live Site Scan, and Analytics.
* Safe deletion workflow with trash & restore.
* Core page builder and plugin compatibility detection.
* Bulk actions, filters, and detailed scan reporting.

== Upgrade Notice ==

= 1.0.0 =
Initial release - all core features included in a single plugin version.

== License ==

GPLv2 or later
