I am trying to find a solution to a problem that Wordpress seems to lack.

Here is a scenario:

I have uploaded images to a post using the native gallery to display the images. These images then appear under the gallery tab within the upload/insert and they will appear on the post. Works perfectly.

Further down the line I create a new post, I want to include images from my Media Library into the gallery without re-uploading the same images again.

I expected to find, "Insert into gallery", next to "Insert into post", but there doesn't seem to be a way of doing this.

Is there a solution to this? I have done a lot of theme development in the past, but amazed at there isn't a simple solution to this problem.

I would be grateful for any help.

1 Answer 1


Attachments are a type of post, and a post can only have a single parent, that's why it's not natively possible to have an attachment associated with multiple posts- there is no mechanism for many-to-many associations. There are several ways to solve this, but how simple it is depends on your skill level or willingness to depend on plugins.

For plugins, there's File Gallery, and Advanced Custom Fields, probably others. Otherwise a couple of custom solutions would be to use post meta data to store references to attachments for a post, and/or a taxonomy to "tag" images for each unique gallery you want them associated with along with some meta data for ordering them.

Here is a thread on WordPress Hackers with an explanation from the lead developer and some possible solutions.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.