Documentation, Reference Materials and Tutorials for Envira Gallery
You may already know you can use the Tags Addon to create a sortable gallery, but you can also display a dynamic gallery populated with specifically tagged images using shortcode.
- Shortcode Attributes
- Ultimate or Pro Envira license. You can read how to upgrade to one of these licenses here.
- WordPress 3.5+
- Envira Gallery 126.96.36.199+
- Tags Addon 1.1.0+
- Dynamic Addon 1.0+
Step 1: Install & Activate Tags Addon
First, you’ll need to install and activate the Tags addon.
Step 2: Add Image Tags
Once the addon is enabled, you’ll have an additional field in the Edit Metadata lightbox for your gallery images to include tags.
You’ll need to add some tags to your images before the shortcode will work, so go ahead and do that now.
Select a gallery to edit, then select the pencil icon at the top of a gallery image. This will bring up the Edit Metadata lightbox where you can enter the tags you wish.
Be sure to select the Save Metadata button before exiting the lightbox and updating your gallery.
You can also add Envira Tags right from the WordPress Media Library. Navigate to Media » Library and click on your image. Add any tags here to be used in your gallery.
Step 3: Add Envira Gallery Shortcode
Now you can include your shortcode in the post or page you desire.
[envira-gallery-dynamic id="tags-rainier,suncadia" default="9"]
In the shortcode example above, we’ll populate a gallery with all images tagged as
suncadia. This will pull images from all galleries you have created on your site.
Assuming there are images found with the tag(s) specified, a gallery will be crafted and cached for your (and your visitors) viewing pleasure.
That’s it, now you have a beautiful tag based dynamic gallery!
Checkout Envira’s Dynamic Addon for more powerful ways to dynamically generate your galleries.
Comma-separated list of tags to populate the gallery with. Use the tag slug and not the tag name or your gallery may not display correctly.
The ID of the gallery whose configuration options the dynamic gallery should use. If using this attribute, it’s important that this gallery exist or your dynamic gallery may not display correctly.