=== NaveenCodes Media Organizer ===
Contributors: shinu1503
Tags: media library, media folders, file manager, unused media, media organizer
Requires at least: 6.5
Tested up to: 6.8
Requires PHP: 8.1
Stable tag: 1.0.0
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Demo URI: https://playground.wordpress.net/?plugin=naveencodes-media-organizer

Organize media into folders, replace files without breaking URLs, find duplicates, and clean up unused files — free, no limits.

== Description ==

**NaveenCodes Media Organizer** adds a clean folder sidebar to your WordPress Media Library and a dedicated Unused Media page — without any cloud service, subscription, or external requests.

= Features =

**Virtual Folders**
Create an unlimited hierarchy of folders directly inside the Media Library. Folders are WordPress taxonomy terms — no extra database tables.

**Folder Sidebar**
A collapsible sidebar appears in the Media Library page with your full folder tree. Click any folder to instantly filter the grid to files in that folder.

**Folder Assignment**
Assign media to a folder from the attachment detail panel (click any image in the media grid). Works in the Media Library, the media modal, and the Edit Media page.

**Bulk Move**
Select multiple files in the media grid, pick a folder, and move them all in one click.

**Unused Media Finder**
A dedicated "Unused Media" page lists every file that is not attached to a post, not embedded in any post content, and not set as a featured image. Delete them individually or in bulk.

**Replace File**
Upload a replacement for any file — the URL, attachment ID, and all page references stay exactly the same. Thumbnails are automatically regenerated.

**Duplicate Finder**
Scans your entire media library for files with identical content (hash-based). Shows them in groups so you can delete extras without losing the original.

**Dashboard Widget**
A quick-glance widget on your WP Admin dashboard shows total files, folder count, and unused file count.

= Privacy =

Everything runs on your server. No data is sent anywhere. No tracking, no analytics, no ads.

= Free, Forever =

No upsells, no premium tier, no usage limits.

❤️ *Dedicated in loving memory of Maa — 18 May.*

== Installation ==

1. Upload the `naveencodes-media-organizer` folder to `/wp-content/plugins/`
2. Activate through **Plugins → Installed Plugins**
3. Go to **Media → Media Library** — the folder sidebar appears on the left
4. Visit **Media → Unused Media** to find and clean up orphaned files

== Frequently Asked Questions ==

= Will organizing folders change my file URLs? =

No. Folders are virtual (WordPress taxonomy terms) and do not affect the physical file paths or URLs of your media.

= Does it work with the Block Editor media modal? =

Yes. The folder dropdown appears in the attachment detail panel in both the media grid and the block editor media modal.

= What does "unused" mean? =

A file is considered unused if it is not attached to any post, not referenced in the content of any published post or page, and not used as a featured image.

= Does it slow down the media library? =

No. Folder filtering uses a standard WordPress taxonomy query — the same mechanism WP uses for its own filters.

= Is it really free? =

Yes. Free forever, every feature included, no ads. Built with care by NaveenCodes.

== Screenshots ==

1. Media Library with folder sidebar — click any folder to filter media.
2. Attachment detail panel with Folder dropdown.
3. Unused Media page — grid view with bulk-delete.
4. Replace File page — upload new file, URL stays the same.
5. Find Duplicates page — scan results grouped by identical content.
6. WP Admin dashboard widget with quick stats.

== Changelog ==

= 1.0.0 =
* Initial release.
* Virtual folder system (unlimited hierarchy, WordPress taxonomy).
* Folder sidebar injected into the Media Library page.
* Folder assignment from attachment detail panel.
* Bulk move selected media to a folder.
* Unused Media finder page with individual and bulk delete.
* Replace File — swap any file while keeping its URL and references intact.
* Find Duplicates — hash-based scan with group view and safe delete.
* WP Admin dashboard widget.

== Upgrade Notice ==

= 1.0.0 =
Initial release — no upgrade action needed.
