1. PROMO Subscribe our All Access Pass @ 75% OFF & access all our 16+ premium Divi extensions: Divi Block Pro, Carousel Toolkit, etc.LEARN MORE
Dismiss Notice
NEW Divi.Help Pro Carousel AI Toolkit - Magically turn your Divi design into carousel, simply by using our online toolkit. No plugins needed. Now it works with Divi 5 as well!Try our carousel AI toolkit
BEST Divi Block - A revolutionary drag & drop tool to easily mix & match 960+ premade blocks (Light & Dark) to kick start your Divi site design. Special module designs are included as well. Also newly added AI generator & color. Now it works with Divi 5 as well!
Learn More About Divi BlockFree Version ~ 340+ Free Blocks

Solved Displaying caption under slider gallery

Discussion in 'Free Divi Community Forum' started by abernatzky, Sep 13, 2021.

  1. abernatzky

    abernatzky New Member

    Hi

    I want to display captions under the gallery in the slider mode, but this is only achievable with custom CSS

    I picked up this CSS snippet below from another thread, but it displays the image "title" and despite my best efforts, I can't get it to reference the caption data instead.
    ____________________________________________________________________________________
    This grabs the "title" data in the link for each photo. Adjust as needed. I reformatted the entire module with:
    .et_post_gallery {padding: 0 0px 30px !important; border-top: 1px #ccc dotted; border-bottom: 1px #ccc dotted; margin-bottom: 30px;}
    .et_pb_gallery_image {padding:30px;}
    .et_pb_gallery_image a[title]:after {content: attr(title); width: 100%; text-align: center; padding: 8px 12px 8px 0; color: #aaa; position: absolute; left:0; top: 100%; z-index: 2; font-size: 80%; font-style: italic;}
    .et-pb-arrow-next, .et-pb-arrow-prev {top: 10%;}
    .et-pb-slider-arrows .et-pb-arrow-prev {left: -6px; color: #ccc !important; opacity: 1;}
    .et_pb_slider:hover .et-pb-arrow-prev {left: -10px; color: #0271b9 !important;}
    .et-pb-slider-arrows .et-pb-arrow-next {right: -6px; color: #ccc !important; opacity: 1;}
    .et_pb_slider:hover .et-pb-arrow-next {right: -10px; color: #0271b9 !important;}
    .et-pb-controllers {bottom: 50px;}
    ______________________________________________________________________________________

    can anyone perhaps point me in the right direction, please?
     
    1. PRO MEMBER PERKS Divi Block Pro - Premade gradient text design for your Divi site without using any plugins:View Demo
  2. Divi.Help

    Divi.Help Administrator
    Staff Member

    There's no caption text available in the HTML markup, thus it's not possible to do that.

    It's either you change the title text as caption, or you may use slider module instead: https://divi.help/threads/how-to-add-caption-on-slider-gallery-for-divi-wordpress.262/
     
  3. abernatzky

    abernatzky New Member

    Oh thank you very much for your response. I will use the titles as Captions then, although this is not ideal for SEO

    what made me think it was possible was that when attempting to modify the code snippet to reference the caption image metadata "caption" and "Captiontext" came up as options in the autocomplete as pictured below. These obviously serve another purpose than I thought.
    [​IMG]
    [​IMG]
     

    Attached Files:

    1. PRO MEMBER PERKS Divi Block Pro - Premade mega menu design for your Divi site without using any plugins:View Demo
  4. Divi.Help

    Divi.Help Administrator
    Staff Member

    The caption is not in the HTML source, so it's not possible to retrieve the value.
     
  5. abernatzky

    abernatzky New Member

    AHHH okay

    Thanks so much for clearing that up
     
    1. PRO MEMBER PERKS Divi Ultimate Header Plugin - Add more varieties for your Divi header (12 premade styles) + menu hover effects:Learn More