jr_get_listing_attachments( $listing_id, $how_many = -1, $type = JR_ATTACHMENT_GALLERY, $fields = '' )
Queries the database for attachments from custom fields or gallery Uses the meta key ‘_jr_attachment_type’ to filter the available attachment types: gallery | file