• Resolved sjones6

    (@sjones6)


    Although the caption is passed as a parameter in the function mg_image_carousel_open_lightbox, it wasn’t displaying.

    I fixed this by adding a title property in the items parameter in the function.

    See lines 19-56 in maxgalleria-image-carousel.js where the function is defined. You’ll notice that the caption parameter is not used anywhere within the function. I added it in the options array started on line 35. My full function call looks like the following:

    ` jQuery(‘.slides’).magnificPopup({
    items: {
    delegate: ‘a’,
    src: image_url,
    title: caption
    },
    type: ‘image’,
    verticalFit: vertical_fit_enabled,
    enableEscapeKey: escape_key_enabled,
    closeOnContentClick: content_click_close_enabled,
    closeOnBgClick: bg_click_close_enabled,
    //closeBtnInside: close_btn_inside_enabled,
    showCloseBtn: hide_close_btn_enabled,
    alignTop: align_top_enabled,
    fixedContentPos: fixed_content_position,
    overflowY: overflowY,
    removalDelay: removal_delay,
    mainClass: popup_main_class,
    retina: {
    ratio: retina_enabled
    }
    });`

    https://wordpress.org/plugins/maxgalleria/

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Error with Captions not Loading in Image Carousel’ is closed to new replies.