WP image editor, replace original image?
-
By default WordPress doesn’t overwrite an existing image if image is edited using built-in image editor, instead of that, new image file is created.
For example, image file: image-file-name.jpg is edited, (for example simple crop/resize), new file is created on disk with some random characters at the end of file name, like this image-file-name-655f4dgfd4g4f.jpg
New image will be used in page/post, but old file will stay on disk, but not used at all. I can’t see option to delete old file, or even to list it/see it. You can delete old image(s) only from FTP.
Is there any function (for functions.php) which will tell WP to replace original image with edited image (or to delete original image after editing).
- The topic ‘WP image editor, replace original image?’ is closed to new replies.