I am customizing this theme . I am using get_the_gallery()
function to get the gallery from the custom post . I am able to do so, but when the gallery is inserted between the shortcodes...
For eg:
[two-third]
[gallery ids="18,17,8,7,6"]
[/two-third]
then i am not able to get the gallery..I am using the following code
<?php
if ( get_post_gallery() ):
$gallery = get_post_gallery( $post, false );
$w3_ids = explode( ",", $gallery['ids'] );
?>
<?php
$gallery_count=1;
foreach( $w3_ids AS $w3_id ):
$src = wp_get_attachment_image_src($w3_id,'full');
?>
<div class="item <?php if($gallery_count==1)echo "active"; ?>">
<img src="<?php echo $src[0]; ?>" alt="" />
</div>
<?php
$gallery_count++;
endforeach;
endif;
?>
What can be done... Please help