Support » Plugin: EWWW Image Optimizer » Plugin generates both jpg and png versions of all sizes and keep them

  • Resolved Doug

    (@nicoblog)


    So i uploaded a picture named DarksidersPC.png, i have this setup to convert png to jpg and it did but it also created all versions of the png image and kept both versions of everything so now i have in my uploads directory:
    DarksidersPC.png
    DarksidersPC-1.jpg
    DarksidersPC-1-150×150.jpg
    DarksidersPC-1-150×150.png
    DarksidersPC-1-238×178.jpg
    DarksidersPC-1-238×178.png
    DarksidersPC-1-300×160.jpg
    DarksidersPC-1-300×160.png
    DarksidersPC-1-80×60.jpg
    DarksidersPC-1-80×60.png

    On the media library only DarksidersPC-1.jpg exist, which is correct. BUT on the uploads folder the PNG version+all the thumbnails in .PNG format exist. Shouldn’t the plugin
    1st) Convert the original png to jpg.
    2nd) Create all the thumbnails for JPG version ONLY!
    3rd) Delete the original PNG version.
    Have a look:
    https://s18.postimg.org/cdrl3fzi1/why.jpg

    • This topic was modified 2 years, 8 months ago by  Doug.
Viewing 2 replies - 1 through 2 (of 2 total)
  • I just realized it does that to be able to restore original later and it can be prevented by checking “Delete originals”.

    I guess my question is…is there any way to bulk remove originals? :S

    Plugin Author nosilver4u

    (@nosilver4u)

    As you found, original uploads are only deleted (after conversion) when “Delete originals” is checked. There isn’t any way that I know of to bulk delete them later. If you have some programming ability (or know someone who does), you could parse through the attachment metadata in the wp_postmeta table of your database, and look for ‘orig_file’ entries and delete those.

    UPDATE: just to clarify, by “delete those”, I mean delete the actual file referenced by the ‘orig_file’ entry, after which you are free to remove the ‘orig_file’ items from the meta.

    • This reply was modified 2 years, 8 months ago by  nosilver4u.
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Plugin generates both jpg and png versions of all sizes and keep them’ is closed to new replies.