You can use the the following attributes for the gallery shortcode:
The problem with this is that the gallery shortcode wraps the image and the caption in different elements(thats why the default solution is using dl-dt-dd), so this will generate one li element for the image, and one for the caption. You can still style it using CSS though, because both of the element has unique classnames.
Related Posts:
- Check if post/page has gallery?
- Automatically add this attribute to the gallery shortcode
- How do i link gallery thumbnails to different url’s using the wp native gallery?
- WordPress gallery ‘post_gallery’ filter doesn’t work with feeds?
- conditional shortcode not working
- Remove width and height attributes from [gallery] output
- Gallery shortcode menu order fix no longer working on WordPress 4.0
- conditional shortcode not working
- Some doubts about gallery shortcode in WordPress
- Should I cache default WordPress gallery shortcode output?
- Numbering Image List in Gallery
- Rewriting WordPress Gallery Shortcode with Bootstrap Carousel
- change wordpress gallery shortcode to slider
- Remove hyperlink on gallery shortcode
- Add custom setting that uses radio button to WP Gallery
- WordPress Gallery shortcode: Display one category ID only
- How to get gallery id inserted to a post?
- Check if post has gallery images/media
- How to Modify WordPress Default Image Gallery Shortcode
- Change WordPress Shortcode added in to post
- Gallery shortcode – change link file image size? (not using default fullsize image)
- add action only if gallery shortcode attribute is equal to?
- Unable to the get the gallery inserted between shortcodes
- Adding shortcode field to edit gallery / Gallery Settings
- How to change the output of gallery shortcode
- Replacement for gallery_shortcode function not taking all attributes
- How to Retrieve data of Gallery Shortcode and display it above a post
- How to copy [gallery] shortcode between posts using polylang [closed]
- Which file renders the “Edit Gallery” Settings page?
- How to display NextGEN gallery in templates?
- Use full size images in a specific gallery
- How to Enable embedding WordPress default gallery in comments?
- How to add new images to existing shortcode configuration?
- Gallery shortcode is empty but magically creates a gallery
- Can we add a single caption to the gallery shortcode?
- Automatically add class-attribute to gallery?
- Replace custom gallery shortcode with default gallery shortcode
- WordPress Gallery with ID’s Shortcode not Working
- Remove width and height attributes from [gallery] output
- Changing layout of defaul gallery output to masonry
- What makes a placeholder resizable in Tinymce?
- how to show last 5 images from the one post gallery
- Gallery Shortcode: using size=”full” doesn’t call the actual thumbnail image size
- Custom shortcode being executed when saving page in wp-admin
- Change appearance of shortcode text inside editor
- Get all posts containing a shortcode
- Splitting Shortcode Attributes not working
- Create a shortcode in WordPress, again
- gutenberg widget outputting paragraph marks
- How to make shortcode output display where I choose
- Change link in get_terms if there is only one post in the category
- How to get total number of shortcodes in the wordpress application?
- WordPress display image link in shortcode
- stop shortcode stripping in category and archive pages
- Passing a nested shortcode as an argument of another shortcode?
- How does one insert a variable value into a “myCRED plugin shortcode [closed]
- Nested Code Snippets [closed]
- How do I display “Hello username” if logged-in on the homepage
- Adding a Cookie Session to Shortcode Content
- Gutenberg Block with Select from JSON-File
- Shortcode function executed twice?
- add widget to page content (using shortcode)
- Pagination for a page created by the shortcode “Product”
- Don’t show images inserted into content
- Shortcodes: closing shortcode not being processed
- Retrieving post excerpt as a shortcode
- Insert PHP code via shortcode?
- Trying to call dynamic content as a shortcode attribute
- What is the correct syntax to append a URL using a shortcode for an iframe?
- Shortcodes in RSS excerpts
- enqueue script with get_shortcode_regex
- How to get_post_meta in a shortcode in excerpt on archive pages
- WordPress upgrade adding additional quote marks to shortcode output
- Creating tabs shortcode
- SImple Example To Update User Info From Front End [duplicate]
- How to: Simple Nested Shortcode [closed]
- get_posts not working on homepage?
- ACF repeater + group shortcode
- Custom shortcode skips every 2nd shortcode
- How to cache a custom API call?
- Shortcode custom query not passing value
- How to create custom variables in wordpress
- Onclick want to call shortcode in wordpress
- Working with Contact Form 7 pipes
- How to disable cache for the content returned by a shortcode
- Hide shortcodes content from the excerpt?
- Can we create a shorcode to move next page?
- launch a shortcode from a link
- how to add acf value to other plugins shortcode?
- Only execute specific shortcodes
- Insert wp gallery shortcode into custom textarea
- About redundant code when I use shortcode to output the HTML from a variable
- Add JavaScript in footer if shortcode used in page [duplicate]
- Is there a way I can return terms by name using a shortcode?
- How i make a shortcode from this code
- Shortcode Attributes – post__not_in array
- Create a shortcode to display the “the_content ()” in my post [closed]
- filter custom field with checkboxes and show it with one shortcode
- How to add button to WYSIWYG to insert shortcode with params (filled in system popup)?
- $m in pre_do_shortcode_tag