We tried with couple of plugins , but there isn’t any with option to bulk delete images by month or year.
If you have access to wp-cli you can try to delete attachments by year and month with:
wp post delete $(wp post list --post_type="attachment" -—year=2016 -—monthnum=12 --format=ids)
or just by year with:
wp post delete $(wp post list --post_type="attachment" -—year=2016 --format=ids)
Remember to backup before testing!!
Related Posts:
- Perform a custom (bulk) action in media view
- Programmatically adding images to the media library with wp_generate_attachment_metadata randomly fails
- How can I bulk delete media and attachments using WP-CLI?
- complex restriction of items in media library
- Edit image / Delete image link
- media_sideload_image file name?
- Get all posts (of any post type) an attachment is used in
- Unattaching unlinked images
- Show Post ID in “Find Posts or Pages” box in Media Library?
- Gel all image from certain post type
- Can i hide the attachments from media which I uploaded from front end?
- Get the attachment URL on single.php
- How to retrieve alt attribute for an attachment (uploaded image)?
- Where does the gallery shortcode gets its attachments from?
- Control attachments menu order with jQuery Sortable
- Is it possible to share media files between multiple WordPress sites?
- Open the Attachment Details popup
- Proper use of wp_get_attachment_image?
- how to get random media id from media gallery
- Upload multiple image with media_handle_upload with multiple file field [duplicate]
- Get an image from the media library. Struggling with the code?
- Media Library Mess After FTP … /uploads
- Media item permalink goes to source file instead of attachment.php
- wp_get_attachment_image_src calling wrong location
- Removing images deleted from uploads folder, from Media Library
- WP media attachment location vs permalink
- Removing delete permanently button in uploading files media
- Retrieve ONLY mp3s and set a variable for use in a playlist called by single.php template?
- Is there a way to add Reattach and Unattach links in image gallery?
- How to retrieve images contained in a post
- How to save media-form on custom tab
- Media library upload hook
- How to manage attachment relationships for specific posts in WP 3.5+
- Change attachment filename
- Uploaded images don’t show in Media Library if there are special characters in IPTC Keywords
- Getting a taxonomy’s thumbnail url
- Check if post has attachments (not image)
- How to get attachment caption (get_the_excerpt gives parent post excerpt) ?
- custom fields for attachments?
- URL rewrite with add_rewrite_rule and attachment_id
- Get attachment from post
- Add column for attachment file size
- Change image link: wp_get_attachment_link
- Multi-line captions on attachments
- ID of images from gallery
- wp_get_attachment_image_src always returns false
- Exact image sizes
- Adding attachment file name to email link
- How to allow specific extensions and file size to wp_mail attachment?
- Is it possible to modify the media library admin screen?
- the_content() behavior on attachment.php versus single.php
- Get attachments by user
- Get url from file uploaded in Media Library
- attachments with tags and get_posts
- Hide “Gallery Settings” and “Insert into Post” button from Attachment window
- How can I change wordpress attachment url and protect it?
- Adding class to next/prev image link in attachment.php
- Getting ID from ajax response of async-upload.php
- How to add multiple checkbox elements to media attachments?
- Get attachment next and previous by author only
- Edit default image attachment size
- Strip the folder path away from wp_get_attachment_url to show filename only
- Need to get array of images ID attached to post
- How to fetch only media that was already attached to a post/page?
- How to set a conditional statement for $attachment->post_excerpt, to check for value?
- Get the bare URL for an attachment
- Attach media to multiple posts
- wp_mail not sending attachment
- How to check if there is image title, caption, description?
- Display random gallery images and its parent post title leading to parent post permalink
- How to remove attachments size attribute [duplicate]
- How do I get all attachments that are used in the current post, not just the children?
- Is there a move_attachment_file() function in wordpress?
- Auto create file and send it via wp_mail()
- Create page from post attachments
- Attach pdf from dynamic url
- Is there a function for getting the post/page that an attachment is related to?
- How to get $attachment->ID in custom functions
- All attachment pages give 404
- How to set order for attachment form field?
- Display a post attachment depending on the caption
- Getting attachment post using wp_get_attachment_link
- File Attachment display title in template
- add image caption
- wp_mail Allow Remote Attachments from CDN
- How can i set media attachments to the author of the post or page for already existed posts with attachments
- Get all post embedded images
- What is wrong with my wp_insert_attachment code?
- flip horizontal images in bulk
- Using the GetMediaLibrary() method in python-wordpress-xmlrpc.media, how to iterate over the result?
- When inserting attachments into a blog post, how can I get WordPress to use the full filename with the extension?
- How to link images to attachment.php [duplicate]
- Check whether attachment ID is associated with more than one post?
- How to remove attachments from main query via pre_get_posts?
- Post attachments doesn’t show after manual db import
- Post images not displaying as attachments
- How to get boolean if file A is attached to post B
- ID of images from gallery
- WPML : how to pick a featured image only once for different languages?
- One audio attachment, with two possible interchangeable extensions