1. Home
  2. Docs
  3. Flexi Gallery
  4. Shortcode
  5. [flexi-gallery]

[flexi-gallery]

This is a shortcode of Flexi Gallery which will display a set of gallery based on filters at shortcode.
Use this shortcode anywhere you like and it is very flexible.
If this contains any attributes it will override the Flexi settings.

Available attributes for [flexi-gallery]

album="slug name of album" : To display gallery of specific album/category. Multiple album separated by commas. The albums can be created from Flexi Category of dashboard.

tag="slug name of tag" : To display gallery of specific Flexi-Post tags. Multiple tags can be inserted separated by commas. The tag can be created from Flexi Tags from dashboard.

tag_show="on,off" : To display related tags just above the gallery.

column="No. of Rows" : Number of post to be displayed per row/horizontally

perpage="No. of total post" : Number of total post to be displayed per page.

orderby="date | title | modified | ID | rand " : 5 different ways the gallery can be sorted.
For eg. If you want to list post with last modified date.
[flexi-gallery orderby="modified"] 

layout="Layout name" : Each gallery can have their own type of layout. There are several default layouts available (i.e. masonry, regular, simple).

popup="on , custom, off" : If the value is on the lightbox is used. The post when clicked will have a popup box instead going to another page. The other page would be a detail page.
custom parameter will use custom layout for the popup which can show/hide different elements.

navigation="page, scroll, button" : Set the navigation style for the gallery. 'page' is for page numbers, 'scroll' is for display gallery on mouse scroll & 'button' is page load more button.

user="username" : The parameter is used to show a post gallery submitted by a particular username.
user="show_mine" : Display gallery based on dynamic logged in user.

Gallery of specific username
[flexi-gallery user="john"] will display all images submitted by username john

If you need dynamic username based on user login.
Eg. [flexi-gallery user="show_mine"] will display gallery of current loggedin user.

width="150" height="150" : In example, the parameter is 150px for thumbnail image height & width. It only changes the image container size without any modification of actual image size

hover_effect="flexi_effect_1| flexi_effect_2| flexi_effect_3" : flexi_effect_1 is a class name with blur effect. Similarly flexi_effect_2 is grayscale & flexi_effect_3 is zoom. It is visible when mouse is moved over the image at gallery.

hover_caption="flexi_caption_none| flexi_caption_1| flexi_caption_2" : flexi_caption_none is will now show any title of image. flexi_caption_1 to flexi_caption_5 is available with different title display. It is visible when mouse is moved over the image at gallery.

clear="true" : This is special attribute required when if you are using multiple gallery one same page. It is built so that all the gallery will be uniquely specified which prevents from conflicts with other gallery.
This will automatically add some settings to it.
a) Disable navigation
b) Disable tags above gallery
c) Each gallery will be given unique name to prevents from multiple popup.

Was this article helpful to you? Yes No

How can we help?