Support

Account

Home Forums Add-ons Gallery Field Colorbox not working with Gallery add-on Reply To: Colorbox not working with Gallery add-on

  • To work with Colorbox, this

    <?php 
     
    $image_ids = get_field('gallery', false, false);
     
    $shortcode = '
     
     
    [gallery ids="' . implode(',', $image_ids) . '"]
    ';
     
    echo do_shortcode( $shortcode );
     
    ?>

    needs to be

    <?php 
     
    $image_ids = get_field('gallery', false, false);
     
    $shortcode = '
     
     
    [gallery ids="' . implode(',', $image_ids) . '", link="file"]
    ';
     
    echo do_shortcode( $shortcode );
     
    ?>