Home › Support › File Un-attach › gallery shortcode not finding attachments v 0.6
April 24, 2012 at 7:34 am #46455orionrushParticipant
I have a short function which I keep in a plugin.
It looks for images attached to a post, and inserts them into the_content.
It works fine for single.php but in loop.php (showing 10 posts at a time) it only works when the images are not attached to any other post.
it seems as if get_children is not seeing the attachments from loop.php???
is there a way to fix this?April 24, 2012 at 8:14 am #46456orionrushParticipant
Hey – I followed this up with a post here on the codex:
I though Im might get feedback from a larger pool of users. So if you respond to this you might do so there where it will help the most people.April 25, 2012 at 1:32 am #46487Xpark MediaKeymaster
get_children will only give you the default attachments, file un-attach uses post meta to assign multiple children to the post “_fun-parent”.
if you are using version 0.5.5 you can use the function “fun_get_attachments( $arg )” this was a contribution by sebmeric get multiple attachments function. Also I need to add the function available arguments to the documentation page.
- You must be logged in to reply to this topic.