Bring Your Business to Life › Support › Image Store › conflict with imsanity / need way to remove orginals
- AuthorPosts
- June 12, 2013 at 8:12 pm #53404DaveParticipant
Hi,
Previously we used a plugin called Imsanity to reduce the file size of all uploaded images. Somewhere along the line (in 3.2.9 and 3.2.7, possibly earlier) we discovered a conflict: After dragging images into the drop-zone to upload, the thumbnails would disappear from the progress list. Once finished uploading, the correct count would appear, but only one (or none) of the uploaded images appeared in the gallery’s thumbnail list. On the file system, multiple sizes were created for just that image, and none of the others.
This problem was resolved by disabling the Imsanity plugin. All uploading worked; multiple sizes were created; and all thumbnails appeared after upload.
However, the problem is now that all the original photos are sitting on the server. They are very large, full quality and take up a lot of space. The point of using Imsanity is to prevent a huge hit against our storage quota. And, of course, we don’t want originals up there on the server to be found.
Is there any way these originals can be removed after uploading? We have 1024 x 768 set as the Max Size in Image Store Settings > Images. We don’t want any images bigger than that… anywhere. Can that be enforced on the originals?
Please advise,
June 16, 2013 at 5:25 pm #53448Xpark MediaKeymasterYou can create a plugin to remove the images once they are uploaded, we recently did it for one of our clients, modify it as needed.
function ims_delete_original_image( $metadata, $attachment_id ){ if (empty($metadata['file']) || 'ims_image' != get_post_type($attachment_id) ) return $metadata; if( file_exists( $metadata['file'] )) @unlink( $metadata['file'] ); return $metadata; } add_filter('wp_generate_attachment_metadata','ims_delete_original_image');
- AuthorPosts
- You must be logged in to reply to this topic.