• Resolved Serkan OZAY

    (@serkan-ozay)


    Hi,

    I’m using tiled gallery with magnific popup plugin. Everthing is good but I’ve a little problem:

    When use any gallery which jetpack provides, captions of images disappears on magnific popup. I tried standart wordpress gallery and captions working without any problem.

    My code for magnific popup is here:

    /*	magnific popup */
    	$('.postWrap a[href$=".jpg"], .postWrap a[href$=".jpeg"], .postWrap a[href$=".png"], .postWrap a[href$=".gif"], .postWrap a[href$=".bmp"]').magnificPopup({
    		type: 'image',
    		closeOnContentClick: false,
    		closeBtnInside: false,
    		image: {
    			verticalFit: true,
    			titleSrc: function(item) {
    				return item.el.find('img').attr('alt');
    			}
    		},
    		gallery: {
    			enabled: true,
    			tCounter: '%curr% / %total%',
    		},
    		callbacks: {
    			open: function () {
    				$('.scrolltotop').hide();
    			},
    			close: function () {
    				$('.scrolltotop').show();
    			}
    		}
    	});

    I believe, ‘img’ and ‘alt’ parts needs change when I use Jetpack’s galleries. But how?

    https://www.ads-software.com/plugins/jetpack/

Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Captions are not shown’ is closed to new replies.