Title: Upload Janitor
Author: michaeltyson
Published: <strong>16 Tháng 1, 2010</strong>
Last modified: 20 Tháng 1, 2010

---

Tìm kiếm plugin

Plugin này **chưa được cập nhật với 3 phiên bản mới nhất của WordPress**. Nó có 
thể không được hỗ trợ và bảo trì, và có thể xung đột với các phiên bản WordPress
mới nhất.

![](https://s.w.org/plugins/geopattern-icon/upload-janitor.svg)

# Upload Janitor

 Bởi [michaeltyson](https://profiles.wordpress.org/michaeltyson/)

[Tải về](https://downloads.wordpress.org/plugin/upload-janitor.0.2.zip)

 * [Chi tiết](https://vi.wordpress.org/plugins/upload-janitor/#description)
 * [Đánh giá](https://vi.wordpress.org/plugins/upload-janitor/#reviews)
 *  [Cài đặt](https://vi.wordpress.org/plugins/upload-janitor/#installation)
 * [Nhà phát triển](https://vi.wordpress.org/plugins/upload-janitor/#developers)

 [Hỗ trợ](https://wordpress.org/support/plugin/upload-janitor/)

## Mô tả

Reclaim disk space and clean up your uploads folder by deleting old uploads you 
are no longer linking to.

This plugin will identify unused files within your uploads folder, and give you 
the option of archiving then deleting
 some or all of these files.

Before any action is taken, Upload Janitor will automatically make a ‘tar’ archive
of all files to be
 erased, including their original paths, so you can restore if
necessary.

### How does it work?

This plugin inspects every file within the uploads folder. For each file, it searches
pages or posts that
 reference the file. That is, the plugin searches for the part
of each file’s path that comes after the path to the uploads folder, such as `2010/
01/my great but forgotten image.jpg`.

The path is searched as-is, as well as URL-encoded with ‘%20’ for spaces, and the
same with ‘+’ for spaces –
 2010/01/my%20great%20but%20forgotten%20image.jpg and`
2010/01/my+great+but+forgotten+image.jpg`. HTML entity-encoded forms of all of these
are also searched.

If no matches are found, then the file is considered unused.

Note that this plugin plays it safe, and does not distinguish between older post/
page revisions and the current version
 of a post/page. If a revision references
a file, the file will be considered still in use.

### Restoring

If something goes wrong, you can always restore. If you have shell access to your
site, this is easy. Simply log in,
 navigate to your `wp-content/plugins` directory,
and locate the Upload Janitor archive – it will look like upload_janitor_archive_YYYY-
mm-dd.tar.gz. Then, type:

    ```
        tar zxf <archive name> .
    ```

This will restore all files within the archive.

If you do not have shell access to your server, you will have to download the archive,
extract it, then upload the
 contents 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

## Cài đặt

 1. Unzip the package, and upload `upload-janitor` to the `wp-content/plugins` directory
 2. Activate the plugin through the ‘Plugins’ menu in WordPress
 3. Visit ‘Upload Janitor’ within the ‘Tools’ menu in WordPress to use

## Đánh giá

![](https://secure.gravatar.com/avatar/a9e1c3b02a34fa228a8b06bc21c3ddf019f45078129cae10f8bd0e474aaef4db?
s=60&d=retro&r=g)

### 󠀁[Not great, lacks features](https://wordpress.org/support/topic/not-great-lacks-features/)󠁿

 [amityweb](https://profiles.wordpress.org/amityweb/) 19 Tháng 5, 2017

This is good in concept but not good in pratice because of the lack of the following
important features: 1) Cant set it to check only media folders (e.g. 2016, 2017 
etc), and it will check the whole Uploads folder. Therefore it reports files as "
not being used" as actually being used, like we have geo location data, ithemes 
security logs, backups etc. We are only interested in the media items, so would 
like to specify media folders 2) Does not show thumbnails, only a list. If you have
an image called 3e67dhw39d3.jpg you have no chance knowing what it is whether you
want to delete it or not 3) It checks the posts if the images are used or not. This
is not actually the best way. What i would expect is to compare the Uploads folder
to the Media section in WordPress. I would like to delete files in uploads that 
are not listed in Media. Instead it is suggesting to delete files that are in Media
but just not in any post (does it even check ACF fields?)

 [ Đọc tất cả 4 đánh giá ](https://wordpress.org/support/plugin/upload-janitor/reviews/)

## Người đóng góp & Lập trình viên

“Upload Janitor” là mã nguồn mở. Những người sau đã đóng góp vào plugin này.

Những người đóng góp

 *   [ michaeltyson ](https://profiles.wordpress.org/michaeltyson/)

[Dịch “Upload Janitor” sang ngôn ngữ của bạn.](https://translate.wordpress.org/projects/wp-plugins/upload-janitor)

### Muốn tham gia phát triển?

[Duyệt code](https://plugins.trac.wordpress.org/browser/upload-janitor/), check 
out [SVN repository](https://plugins.svn.wordpress.org/upload-janitor/), hoặc theo
dõi [nhật ký phát triển](https://plugins.trac.wordpress.org/log/upload-janitor/)
qua [RSS](https://plugins.trac.wordpress.org/log/upload-janitor/?limit=100&mode=stop_on_copy&format=rss).

## Nhật ký thay đổi

#### 0.2

 * Tweak for compatibility with some apparently buggy PHP installations
 * Additional error reporting for ‘tar’ archiver

#### 0.1

 * Initial release

## Meta

 *  Phiên bản **0.2**
 *  Cập nhật lần cuối **17 năm trước**
 *  Số lượt cài đặt **40+**
 *  Phiên bản WordPress ** 2.6 hoặc cao hơn **
 *  Đã kiểm tra lên đến **2.9.2**
 *  Ngôn ngữ
 * [English (US)](https://wordpress.org/plugins/upload-janitor/)
 * Thẻ
 * [clean](https://vi.wordpress.org/plugins/tags/clean/)[delete](https://vi.wordpress.org/plugins/tags/delete/)
   [files](https://vi.wordpress.org/plugins/tags/files/)[unused](https://vi.wordpress.org/plugins/tags/unused/)
   [upload](https://vi.wordpress.org/plugins/tags/upload/)
 *  [Nâng cao](https://vi.wordpress.org/plugins/upload-janitor/advanced/)

## Đánh giá

 4 trên 5 sao.

 *  [  2 5-star reviews     ](https://wordpress.org/support/plugin/upload-janitor/reviews/?filter=5)
 *  [  1 4-star review     ](https://wordpress.org/support/plugin/upload-janitor/reviews/?filter=4)
 *  [  0 3-star reviews     ](https://wordpress.org/support/plugin/upload-janitor/reviews/?filter=3)
 *  [  1 2-star review     ](https://wordpress.org/support/plugin/upload-janitor/reviews/?filter=2)
 *  [  0 1-star reviews     ](https://wordpress.org/support/plugin/upload-janitor/reviews/?filter=1)

[Your review](https://wordpress.org/support/plugin/upload-janitor/reviews/#new-post)

[Xem tất cả đánh giá](https://wordpress.org/support/plugin/upload-janitor/reviews/)

## Những người đóng góp

 *   [ michaeltyson ](https://profiles.wordpress.org/michaeltyson/)

## Hỗ trợ

Có điều gì muốn nói? cần giúp đỡ?

 [Xem diễn đàn hỗ trợ](https://wordpress.org/support/plugin/upload-janitor/)

## Ủng hộ

Bạn có muốn hỗ trợ vào sự phát triển của plugin này?

 [ Ủng hộ plugin này ](http://atastypixel.com/blog/wordpress/plugins/upload-janitor)