Envira Gallery Documentation

Documentation, Reference Materials and Tutorials for Envira Gallery

Display a Tag Based Dynamic Gallery

Would you like to create a tag based dynamic gallery? With Envira this is simple and easy to do with a little help from 2 of our addons. This tutorial will walk you through all the steps needed to create a tag based dynamic gallery.


First, you’ll need to install and activate the Envira Tags Addon and the Envira Dynamic Addon.

Please follow our instructions on how to install and activate addons.

There are multiple ways to tag your images with Envira Tags.

You can easily tag your images from any Envira gallery by editing your gallery images.

First, select a gallery to edit.

Next, select the blue pencil icon at the top of a gallery image.

Edit your gallery images by clicking the blue pencil icon

The Edit Metadata window will open and here you’ll enter the tags on your gallery images on the Tags field.

Add tags to individual images in your gallery through the Edit Metadata window.

Be sure to select the Save Metadata button after each image to save the changes.

When you’re finished adding your tags, close the Edit Metadata window by clicking the X button in the top right corner.

Then click Update on your gallery.

You can also add Envira Tags right from the WordPress Media Library.

To start, navigate to Media » Library and select the image you want to tag.

In the Envira Tags field, just type in your tag and click Update to save your changes after each image you edit.

Add your Envira tags so that you can later create your tag based dynamic gallery

Edit the Envira Dynamic Gallery to configure your gallery settings for all dynamic galleries on your site.

Once activated, the Dynamic Addon will add a gallery item in the Envira Gallery List view which you can configure to control the default appearance of all Dynamic galleries.

Finally, just add your dynamic shortcode to any page, post or widget area on your site.

You’ll first need to get the slug name of the tags you want to use.

To do this, go to Media » Envira Tags.

In the Slug column, copy the slug name for each tag. These are usually lowercased. Any spaces are separated with hyphens.

Find your Envira tag slug name under the Envira Tag menu

For the purpose of this documentation, we’re going to create a tag based dynamic gallery using all images tagged as rainier or suncadia.

Our shortcode would look like this:

[envira-gallery-dynamic id="tags-rainier,suncadia"]

Any images tagged in your galleries or in the WordPress Media Library with either of those tags would show in your dynamic gallery.

Dynamic Tags Gallery

That’s it, now you have a beautiful tag based dynamic gallery!

Would you like to do more with the Dynamic Addon? Checkout Envira’s Dynamic Addon for more powerful ways to dynamically generate your galleries.


A: Absolutely! You’ll use the same concept but instead of tagging your images, you’ll be tagging your galleries.

When you activate the Tags Addon, you’ll see a sidebar box show on your gallery pages called Envira Categories.

Create a tag based dynamic album too

Just click Add New Category under the Envira Categories sidebar.

Type in your category name and click Add New Category button.

You’ll still need to use the slug name for the category.

Get the slug name for the Envira Category to create a tag based dynamic album

Then your dynamic album should code would like this:

[envira-album-dynamic id="tags-music"]

That shortcode would populate your dynamic album with any galleries that have been assigned the Music category.


A: Of course!
By default, a tag based dynamic gallery will check for images that match each individual tag.

However, if you want to match only images which contain all the tags indicated in the shortcode you can add operator="AND" to the shortcode.

Example: [envira-gallery-dynamic id="tags-one,two,three" operator="AND" default="2475"]

That shortcode would only show images that have been tagged with one, two and three.

[i]
[i]