Skip to content Skip to sidebar Skip to footer

Fancybox With Mutiple Title On Right Side Of Image

I need to show image title, date and link on the right side of the image. something similar to this example by default fancybox allow us few option like inside, outside, top but no

Solution 1:

You can use fancybox tpl (template) option and add information on callback like afterLoad like so:

$(".fancybox").fancybox({
    helpers : {
        title: {
            type: 'inside',
            position: 'top'
        }
    },
    nextEffect: 'fade',
    prevEffect: 'fade',
    afterLoad: function() {
        var html = '<span>Date, File Type, Download</span>';
        $('.fancybox-sidebar').append(html);
    },
    tpl: {
        wrap     : '<div class="fancybox-wrap" tabIndex="-1"><div class="fancybox-skin"><div class="fancybox-outer"><div class="fancybox-inner"></div><div class="fancybox-sidebar"></div></div></div></div>'
    }
});

DEMO


Post a Comment for "Fancybox With Mutiple Title On Right Side Of Image"