[wp-trac] [WordPress Trac] #48194: Unregistered image sizes used for IMG tag "srcset"
WordPress Trac
noreply at wordpress.org
Wed Oct 2 02:16:24 UTC 2019
#48194: Unregistered image sizes used for IMG tag "srcset"
--------------------------+-----------------------------
Reporter: galbaras | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Media | Version:
Severity: normal | Keywords:
Focuses: |
--------------------------+-----------------------------
Following design changes, previously-generated thumbnails remain on the
site, along with matching post meta entries linked to the respective
attachment. WordPress then uses those to produce IMG tags.
In fact, these thumbnails are referenced even when the files don't exist
on the site anymore, following a cleanup.
I think WordPress should only use thumbnail URLs for registered image
sizes.
For bonus points, there can be a way to remove unregistered size
references from attachment meta, perhaps in a Media > Audit admin page,
which lets the user decide what to remove and what to keep.
For context, I've just cleaned images on a site and found a lot of legacy
references to thumbnails of previously registered sizes in IMG tags. Media
management and cleanup plugins I used could only detect the redundant meta
data when I re-registered the old sizes temporarily.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/48194>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list