Pro blocks

Dynamic GalleryPro

How to create Media Categories and assign them to images, how the filter buttons work, and how to set up the lightbox, overlay, titles and captions, and pagination.

This feature needs the Pro version of WPMozo Blocks and Addons.

On this page

See the Dynamic Gallery block live on the demo site (opens in a new tab)

Before you start: Media Categories#

The Pro plugin adds a Media Categories taxonomy to your media.

  1. Go to Media → Media Categories and create categories, for example Weddings, Portraits, Events.
  2. Open any image in Media → Library and assign one or more categories to it.
  3. These categories become the gallery filters.

Adding the block#

  1. Click the “+” (Block Inserter) button.
  2. Search for “Dynamic Gallery” and select it.
  3. Under Configuration → Includes Categories, choose the media categories to show.

General tab#

Configuration#

Configuration settings
SettingDescription
Number of ImagesHow many images to load (per page when pagination is on).
Offset NumberSkips this many images.
Order by / OrderSort by Date, Modified Date, Title, Slug, or ID, in DESC or ASC order.
Includes CategoriesMedia categories to show in the gallery and as filters.
Empty gallery textMessage shown when no images are found.
Number Of ColumnsImages per row.
Column SpacingGap between images.
Image SizeThumbnail, Medium, Large, or Full.
Click TriggerWhat happens on click: None, Lightbox (open the image in a popup), or Link (go to a URL, in the Same Window or a New Window).
Images Transition DurationSpeed of the filter animation, in ms.

Elements#

Elements settings
SettingDescription
Show FiltersShows the category filter buttons above the gallery.
Show All Images Filter / All Images TextAdds an “All” button and lets you rename it.
Show Title / Show Title inShows the image title in the Lightbox Only, Gallery Only, Overlay, or Both Gallery and Lightbox.
Show Caption / Show Caption inSame choices, for the image caption.
Enable Overlay on HoverAdds a color overlay when the visitor hovers over an image.
Show Overlay IconShows an icon (for example a zoom icon) on the overlay.
Lightbox settings
SettingDescription
Lightbox EffectOpen animation: None, Zoom, or Fade.
Enable NavigationPrevious and next arrows inside the lightbox.
Title & Caption StyleShows text as an Image Overlay or Below Image in the lightbox.

Pagination#

Pagination settings
SettingDescription
Show PaginationSplits the gallery into pages, using Number of Images per page.
Show Previous Next LinksAdds previous and next links, with custom Prev Link Text and Next Link Text.

Design tab#

Category filter design settings
PanelWhat it controls
ImagesImage border and radius.
TitleTitle Level, alignment, color, and typography of image titles.
CaptionCaption alignment, color, and typography.
CategoryFilter buttons, with Normal / Active background, text color, typography, border, and radius.
OverlayOverlay Background Color, Overlay Icon Size, and Overlay Icon Color.
LightboxLightbox Color (the backdrop behind the image).
PaginationNormal and active page-number background and text colors.

Advanced tab#

See Common Advanced Settings.

Tips#

  • Give an image several categories to show it under more than one filter.
  • Use Image Size → Medium or Large for fast loading, because the lightbox still opens the full image.

Was this article helpful?

Updated Nov 2, 2026