{"id":7841,"date":"2010-01-16T22:31:45","date_gmt":"2010-01-16T22:31:45","guid":{"rendered":"https:\/\/wordpress.org\/plugins-wp\/upload-janitor\/"},"modified":"2010-01-20T15:00:48","modified_gmt":"2010-01-20T15:00:48","slug":"upload-janitor","status":"publish","type":"plugin","link":"https:\/\/pcd.wordpress.org\/plugins\/upload-janitor\/","author":1144815,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_crdt_document":"","version":"0.2","stable_tag":"0.2","tested":"2.9.2","requires":"2.6","requires_php":"","requires_plugins":"","header_name":"Upload Janitor","header_author":"Michael Tyson","header_description":"","assets_banners_color":"","last_updated":"2010-01-20 15:00:48","external_support_url":"","external_repository_url":"","donate_link":"http:\/\/atastypixel.com\/blog\/wordpress\/plugins\/upload-janitor","header_plugin_uri":"http:\/\/atastypixel.com\/blog\/wordpress\/plugins\/upload-janitor","header_author_uri":"http:\/\/atastypixel.com\/blog","rating":4,"author_block_rating":0,"active_installs":50,"downloads":8681,"num_ratings":4,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","changelog"],"tags":[],"upgrade_notice":{"0.2":"<ul>\n<li>Please upgrade if you are experiencing errors or a blank screen when using Upload Janitor<\/li>\n<\/ul>","0.1":"<ul>\n<li>Initial release<\/li>\n<\/ul>"},"ratings":{"1":0,"2":"1","3":0,"4":"1","5":"2"},"assets_icons":[],"assets_banners":[],"assets_blueprints":{},"all_blocks":[],"tagged_versions":["0.1","0.2"],"block_files":[],"assets_screenshots":[],"screenshots":[],"jetpack_post_was_ever_published":false},"plugin_section":[],"plugin_tags":[4657,2872,88,17749,259],"plugin_category":[50],"plugin_contributors":[],"plugin_business_model":[],"class_list":["post-7841","plugin","type-plugin","status-publish","hentry","plugin_tags-clean","plugin_tags-delete","plugin_tags-files","plugin_tags-unused","plugin_tags-upload","plugin_category-media","plugin_committers-michaeltyson"],"banners":[],"icons":{"svg":false,"icon":"https:\/\/s.w.org\/plugins\/geopattern-icon\/upload-janitor.svg","icon_2x":false,"generated":true},"screenshots":[],"raw_content":"<!--section=description-->\n<p>Reclaim disk space and clean up your uploads folder by deleting old uploads you are no longer linking to.<\/p>\n\n<p>This plugin will identify unused files within your uploads folder, and give you the option of archiving then deleting\nsome or all of these files.<\/p>\n\n<p>Before any action is taken, Upload Janitor will automatically make a 'tar' archive of all files to be\nerased, including their original paths, so you can restore if necessary.<\/p>\n\n<h3>How does it work?<\/h3>\n\n<p>This plugin inspects every file within the uploads folder.  For each file, it searches pages or posts that\nreference the file.  That is, the plugin searches for the part of each file's path that comes after the path \nto the uploads folder, such as <code>2010\/01\/my great but forgotten image.jpg<\/code>.<\/p>\n\n<p>The path is searched as-is, as well as URL-encoded with '%20' for spaces, and the same with '+' for spaces -\n    2010\/01\/my%20great%20but%20forgotten%20image.jpg and <code>2010\/01\/my+great+but+forgotten+image.jpg<\/code>.  HTML entity-encoded\nforms of all of these are also searched.<\/p>\n\n<p>If no matches are found, then the file is considered unused.<\/p>\n\n<p>Note that this plugin plays it safe, and does not distinguish between older post\/page revisions and the current version \nof a post\/page.  If a revision references a file, the file will be considered still in use.<\/p>\n\n<h3>Restoring<\/h3>\n\n<p>If something goes wrong, you can always restore.  If you have shell access to your site, this is easy.  Simply log in,\nnavigate to your <code>wp-content\/plugins<\/code> directory, and locate the Upload Janitor archive - it will look like \n    upload_janitor_archive_YYYY-mm-dd.tar.gz.  Then, type:<\/p>\n\n<pre><code>    tar zxf &lt;archive name&gt; .\n<\/code><\/pre>\n\n<p>This will restore all files within the archive.<\/p>\n\n<p>If you do not have shell access to your server, you will have to download the archive, extract it, then upload the\ncontents back to your server.  The archive will be accessible at http:\/\/your-blog.com\/wp-content\/uploads\/upload_janitor_archive_YYYY-mm-dd.tar.gz<\/p>\n\n<!--section=installation-->\n<ol>\n<li>Unzip the package, and upload <code>upload-janitor<\/code> to the <code>wp-content\/plugins<\/code> directory<\/li>\n<li>Activate the plugin through the 'Plugins' menu in WordPress<\/li>\n<li>Visit 'Upload Janitor' within the 'Tools' menu in WordPress to use<\/li>\n<\/ol>\n\n<!--section=changelog-->\n<h4>0.2<\/h4>\n\n<ul>\n<li>Tweak for compatibility with some apparently buggy PHP installations<\/li>\n<li>Additional error reporting for 'tar' archiver<\/li>\n<\/ul>\n\n<h4>0.1<\/h4>\n\n<ul>\n<li>Initial release<\/li>\n<\/ul>","raw_excerpt":"Clean up unused images and other files from your uploads folder.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/7841","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=7841"}],"author":[{"embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/michaeltyson"}],"wp:attachment":[{"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=7841"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=7841"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=7841"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=7841"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=7841"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/pcd.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=7841"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}