Media library upkeep
This page is for the owner and the person on the team who looks after images and files. The media library is a part of the content tree kept for content that other content uses: images, files, videos. Every upload is a content item of its own (Images, media and uploads). Without a few rules it fills with duplicates and files nobody uses; with them, editors find what they need in seconds.
Contents
Rules to agree once
| Rule | Why | Source |
|---|---|---|
| One folder structure, at most three levels deep | the upload dialog browses at most three levels (MaxDepth=3 in settings/upload.ini) | Organizing the media library |
| Folders by topic, by year and month, or by site | pick the one your editors think in | same |
A Shared folder for logos and icons | used everywhere, owned by one person | same |
| Name images by what they show | the name becomes the item's title and the suggestion for the alternative text | same |
| Every image with an alternative text | for screen readers and when an image cannot load | Images, media and uploads |
| Upload once, reuse by relation | a second copy is a second item to keep up to date | Relations and content reuse |
Write the rules into your editor guide and the Image and file guidelines.
Who does what
| Task | Who | How often |
|---|---|---|
| Upload into the right folder, with title and alternative text | every editor | each upload |
| Look at the newest uploads in the media library | media owner | weekly |
| Run the clean-up below | media owner with the administrator | quarterly |
| Decide what to do with large or old files | owner | when the clean-up finds them |
The upload page marks a file with the same name and size already in the location, and lets you skip it (Images, media and uploads). Encourage editors to skip rather than "upload anyway".
The quarterly clean-up
The content checks find what is unused or broken (The content checks). They are in the Setup menu and in the content tree's context menu (Advanced), and only Administrator has them on a new installation, so do this with your administrator or ask for the policies.
- Unreferenced objects in Media. The published images, files and media below a node that nothing uses: no other object, layout, setting, template, role, shop or newsletter entry. Review the list and move what is truly unused to the trash.
- Broken relations from the content root. Visible content that points to something deleted, hidden, in the trash or never published, with a link to edit the source. Fix each source.
- Missing files. Images and files whose file is gone from the storage (Missing files). Upload them again or remove the item.
- Storage files. Files on disk no content uses. They can be moved to a quarantine and deleted from there later; nothing is deleted from the storage directly.
- Empty the trash only later. Leave trashed media in the trash for a while in case something still needed them (Archiving and the trash).
Tip
Before removing an image, open its reverse relations: the administration warns before you remove an image that something still uses (Reverse relation check).
What to ask your administrator
- The policies
contentcheck/unreferencedandcontentcheck/brokenrelationsfor the media owner, if you want them to run the checks themselves. - Which file types and sizes uploads accept. The upload page shows the largest file it accepts; the allowed image
types are set in
settings/image.ini(SVG and image formats). - That
var/<site>/storageis in the backups (Backups and restores). - That the content check report can run from the command line (
./console exp:content-check) if you want it monthly.
Related pages
- Images, media and uploads
- Image and file guidelines
- Broken links and content checks
- Free documentation: this page is free to copy, translate and improve under the GNU FDL 1.3.
Become an Exponential Partner
Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.