This works for me: http://wordpress.org/support/topic/detach-amp-re-attach-media-attachment-images-from-posts#post-1609173
I’ve saved this as a snippet in my IDE for use in projects. Very handy!
Related Posts:
- Responsive Images
- Use Media Library to manage galleries like Nextgen (with folders, albums, collections, tags, categories, terms…)
- Add size in Gallery Settings in Media Library
- Define size for `get_post_gallery_images`, they seem to have been resized to 150×150
- Media gallery – inserting full size images without link
- How to Add a Custom Colum on Thickbox Media Gallery Tab?
- Getting the image title/alt attribute from the gallery shortcode
- Add data attribute to a gallery link?
- Large Media Library
- Add Download Button in prettyPhoto Plugin
- Gallery Image Numbers?
- Extending Media Gallery – Retrieving values from short code
- How to run custom JavaScript code on gallery attachment image selection
- Original image not saving?
- Display number of latest images from wordpress gallery in your homepage
- Why do the images only display in original size, not my custom size?
- Display Gallery Images from Custom Post Type
- Ipad app: Need uploaded images to go into “Gallery” as well as “Media Library”
- Gallery – custom html for inserting images
- Media Categories as Classes on WordPress Gallery Shortcode
- Display custom gallery in each wordpress post
- Add anchor tag on previous_image_link / next_image_link
- How to delete resized (cropped) image uploads and prevent future resizing?
- Gallery Inside One Post
- How do i add class=”fancybox” to the default gallery?
- Post slugs and images cannot have same name?
- Cropped featured image replaces original image in gallery
- how do i create a downloadable gallery with image descriptions?
- Download external images if post is publish
- Can I load posts via Ajax?
- add_image_size creating lots of images (of various sizes)
- Register an additional image size for only some images in my media library
- Admin Media grid view images won’t load
- How to remove title attribute from gallery links and images
- The WordPress Gallery, Grabbing The Link and Images?
- Post photo galleries [closed]
- Cannot access the thumbnails of attachment images… Cannot find the reason
- Get a Page’s attachments in Gallery order
- remove featured image from gallery woocommerce [closed]
- Upload images from custom plugin using the media modal
- Display all albums in nggallery on a page [closed]
- how do i embed the pdf gallery in wordpress post
- WordPress gallery not sorting the images if I change the order of image ids
- GalleryView binding for WP Gallery, without NextGen
- Gallery post images on homepage?
- How to get media objects
- Exclude featured image from gallery in wp-admin
- Gutenberg MediaUpload component with default gallery functionality?
- How to output images as figure/figcaption
- Add Image Size for one Media Category Only
- wordpress get gallery images title
- Displaying a combination of Galleries
- Customizing the attachement page to show rest of all images in a gallery from post
- Upload multiple images to a Woocomerce product
- What is the alternative to “ when it comes to calling Media (image) files in the ‘attachment.php’ file?
- How to make a gallery with dynamic images from URLs?
- Add custom text in the media library image meta area
- Unable to upload images to the Media Library. Getting this erron on the console wp-admin/async-upload.php 403 (Forbidden)
- media-library: how to insert thumbnails with a fixed width, regardless of landscape/portrait orientation
- WordPress automatically adds links to uploaded images
- Recalibrate _wp_attachment_metadata Image Dimensions
- Load Gallery Images with Title on Homepage BX Slider
- Making a [gallery] in a loop with attachment IDs?
- How can I attach a gallery to a post with a short code?
- Create a post from every image in my media gallery
- Remove curved edges from thumbnails in gallery (elementor)
- Auto delete pictures in media library by age
- Add image to gallery with slug
- How to remove the images from “Uploaded to this post”?
- Image thumbnails slider
- How to get the next and previous image title from attachment or gallery?
- changing the default picture size link url
- A proper gallery in wordpress?
- is there a jcarousel plugin for wordpress that loads dynamic images
- Looking for WordPress Slideshow Gallery Plugin [closed]
- Images getting smashed
- unsharp thumbnails after uploading image
- How to make in wordpress a gallery with 3 colums to 1 on mobile devices responsive?
- Lightbox not showing image caption
- How to re-arrange images in default WP Gallery more than one image at once?
- Convert multiple image blocks to gallery block in Gutenberg?
- Post images are not displayed in media library
- After moving a site to new hosting, not all images are showing in media library
- Schedule image post on download
- Extract Gallery picture info from empty gallery shortcode
- Gallery attachment not found
- Responsive WordPress Gallery
- Display images with same specific value?
- Standard WordPress gallery – Possible to open image in page?
- How to display every pictures from all the posts on one page?
- How to add multiple images in a page
- Get raw image detail from post gallery?
- Broken Media Library
- Category page with gallery for each post
- Any plugins that upload, resize, and display images? [closed]
- Get post image gallery link
- Adding different classes to different images depending on size for fine control of image layout in posts
- Get attachment if matches a variable
- Images uploaded in customized gallery do not link to media
- Trouble with WordPress Gallery since update using has_block(‘gallery’