Change Attachment Parent allows you to edit the parent value of anything in the media library.
This becomes useful if you have uploaded images you’d like to place in a post’s gallery that are not currently children of that post.
I’ve also found that sometimes you add a new post with photos and they are not added to the gallery because you hadn’t saved the post when you uploaded them. This allows you to associate those photos with the post.
The interface isn’t that user friendly, you must enter the post ID, and I’d appreciate feedback on how to improve this.
Installation
1. Extract change-post-attachment.zip and place change-post-attachment.php `/wp-content/plugins/` directory
2. Activate the plugin through the ‘Plugins’ menu in WordPress
Download
Download the plugin from the wordpress plugins page.
August 6th, 2009 at 11:50 am
Hey, I tried out your plugin, but it doesn’t seem to work.
I have tried changing the parent-attachment ID of an image I have attached to page ID 508 to ID 11 (which exists) .. and when go to update it, the image still shows up as being attached to post ID 508. I have tried this for a number of different attachments and different post IDs and it doesn’t seem to work.
Using Wordpress 2.8.3.
Any help would be much appreciated.
Thanks,
// mike
August 14th, 2009 at 4:04 pm
@Mike Thanks for pointing that out. I have no idea how this happened but the update portion of the plugin somehow got removed in the version I posted to the Wordpress plugin gallery. I’ve updated it to version 0.3 and it should all be good now.
August 19th, 2009 at 8:50 pm
Works perfectly!
Awesome!
It’s one of the 3 top plugins I’m using in particular with the Media Library, I think I am going to write a post on my site about it!
Cheers!
// mike
August 19th, 2009 at 9:18 pm
I’m glad it’s working for you now! I’d like to make it a bit easier to use, but the site it was designed for has thousands of posts, which makes it difficult to do something like a dropdown box. Any suggestions for improvement are welcome.
September 23rd, 2009 at 3:39 am
[...] liebe Mikro-Plugins! Z.B. Change Attachment Parent von Joel Sholdice, es hat nur 30 Zeilen Code, davon gehören 8 zum Header und zwei sind [...]
October 11th, 2009 at 1:47 am
Thanks for the plug-in. It solved my problem of how to add and delete existing picture from a gallery.
October 30th, 2009 at 2:59 pm
Wordpress 2.9 includes the ability to locate and attach media which are currently un-attached; but it does not include the ability to change the parent of an already-attached file. THANK YOU for this!
You might look into using the “locate post or page” logic that WP 2.9 uses, in addition to being able to specify an ID directly.
December 2nd, 2009 at 1:10 pm
Great plugin. You know what would be great is if you could do the edit from the Library list instead of having to click into every attachment. That would make bulk changes much easier. Even without this it’s a big help, thanks!