#12917 closed defect (bug) (invalid)
Unable to browser media library within custom post type
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Priority: | normal | |
Severity: | normal | Version: | 3.0 |
Component: | General | Keywords: | |
Focuses: | Cc: |
Description
When creating/editing a custom post type "post" in 3.0 beta, you are unable to access the media library using the "Add Image" browser.
If you click the "Media Library" tab in the Thickbox popup, it correctly counts the number of items in the library, but doesn't show any of them. This makes it impossible to use already uploaded images for post content or thumbnails.
If you upload an image on that post, the "Gallery (n)" tab appears as expected.
I've uploaded a screenshot in case my description wasn't awesome.
Attachments (1)
Change History (7)
#2
@
11 years ago
Thanks for checking scribu.
I investigated further, thinking that the problem may have been with my custom post type being named 'media'. I didn't think that it should cause a problem, since WP's media library uses a post type of 'attachment'.
The problem turned out to be that I added a taxonomy of "type" to the "media" post type. Again, that didn't seem to be a clash with WP's built-in taxonomies, but removing it solved the problem. So, unless the taxonomy of "type" is somehow actually reserved, there's a problem somewhere in the register_taxonomy() API.
Can't reproduce.
Usign r14041 and a post type 'test', the media gallery works normally (the thickbox is missing it's title, though).