[slideshow name="id_of_slideshow"]
[query post_type="post" posts_per_page="5" /]
[/slideshow]
More on [query], [slideshow] and [post_list] shortcodes.
[slideshow name="id_of_slideshow" galleries="name_of_gallery" /]
Or for instance, if you have 3 blog posts that you want to display in a slideshow on your homepage, do exactly the same as in the previous example, just add blog posts not images to the gallery.
More on Slideshows and the [gallery_list] shortcode.
In the Dottoro theme, you can create multiple galleries for every page and post, moreover global galleries can also be created. Global galleries are mostly useful when you want to display a gallery on more than one page. For instance, when you want to display a slideshow on the header, footer or sidebar. If a gallery is related to a page or post, it is advisable to add the gallery to the page/post instead of creating a global gallery.
Global galleries can be managed under the "Galleries" main menu, while post and page galleries by clicking on the "Edit Galleries" button in the "Dottoro Galleries" metabox on the edit post screen.
The Dottoro gallery editor works the same way as the WordPress menu editor.
You will find the galleries in the right column.
To create a new gallery click on the plus sign (+) on the top of the right column. Give your gallery a name and save it.
The left column makes it possible to add items to a gallery:
If you take a look at the top of a gallery, you will see a Gallery Popup option. It allows you to select a gallery popup window for the gallery. If the gallery should be shown in a popup window, this setting determines which one will it be.
If the Gallery Popup option is set to default
Gallery popups can be managed under Popups » Gallery Popups. There are predefined gallery popups you can choose from and you can also create custom ones.
Currently gallery popups always display the gallery in a slideshow, but if the need arises, they will be extended to be able to display listings also.
For further details, please see the Gallery Popup option under Theme Options » General and the Popup Slideshows section.
If you take a look at the top-right corner of the Gallery Editor, you will see a "Default gallery" option (only available for post and page galleries and not for global galleries).
It allows you to select the default gallery of a post.
This is a convenience function.
If the gallery is not specified for a slideshow and [gallery_list] shortcodes, they display the default gallery of the post.
Similarly, if the gallery is not specified for the [gallery_button] and [popup_opener] shortcodes, they open a popup slideshow displaying the default gallery.
Displays a gallery as a list.
The gallery_list shortcode allows you to display any number of galleries in a listing and to specify the number of layout columns, the rendering order and whether the items should be displayed in a grid layout or not.
Additionally, it is also possible to query for posts and display them or their galleries as a list. For these cases, you should use a [query] shortcode nested into the gallery_list shortcode. For details, see the galleries attribute.
Finally, there are further shortcodes that can be nested into the gallery_list shortcode.
These are the [item_settings], [popup_gallery_settings], [selector], [empty_list], [before_list], [after_list] shortcodes.
With the help of these shortcodes, you can specify the size of images, the length of excerpts and more.
Attributes | |
---|---|
galleries |
Specifies the name of a gallery or a comma separated list of gallery names that should be displayed in the list.
Additionally, you can also use the post_id:gallery_name syntax to refer to a gallery of another post or a global gallery. For instance, "23:gallery1" refers to the "gallery1" gallery of the post with id of 23, "0:gallery1" refers to the "gallery1" global gallery. Finally, there is a special value, the "_default" that identifies the default gallery of a post. For instance, if the "galleries" attribute is set to "_default" and a [query] shortcode nested into the gallery_list shortcode, the default galleries of the queried posts will be displayed in the list. More on Galleries and the Default Gallery. |
group | Specifies a group identifier or a comma separated list of group identifiers for the posts appearing in the list. This attribute is useful if there are multiple post lists, gallery lists and/or slideshows on the same page and you want each post to appear at most once. In this case, just give the same group identifier to the post lists, gallery lists and slideshows and they will display different posts. |
List Layout settings | |
col_num | The number of layout columns |
grid_layout |
Set whether the list items should be displayed in a grid or the cell height is determined by its content.
Possible values: false, true. Default: true. |
rendering_order | Specifies whether the list items should be rendered left to right or top to bottom in multi-column layout (left_right | top_bottom). Default: left_right. |
You have the following options:
[gallery_list galleries="name_of_gallery" col_num="2" /]
Similar as in previous example, create a gallery for your homepage contaning the posts you want to display and use the [gallery_list] shortcode to display them:
[gallery_list galleries="name_of_gallery" col_num="2" /]
Create a global gallery ("Galleries" menu on the admin screen) and add a [gallery_list] shortcode to the post template used for the posts (more on Post Templates).
Since you want to display a global gallery not a gallery of the current post, the post id must be specified in the galleries attribute ("0:" for global galleries).
Sample code:
[gallery_list galleries="0:name_of_gallery" col_num="2" /]
Simply add a [gallery_list] shortcode to the post template used for the posts (more on Post Templates). Since you want to display the default gallery of the post, the gallery does not need to be specified for the gallery_list shortcode:
[gallery_list col_num="2" /]
The answer is the same as in the previous example, but the gallery must be specified for the [gallery_list] shortcode:
[gallery_list galleries="my-gallery" col_num="2" /]
[gallery_list galleries="name_of_gallery" col_num="3"]
[item_settings media_width="300" media_height="200" /]
[/gallery_list]
[gallery_list galleries="name_of_gallery" col_num="3"]
[item_settings media_width="300" media_height="200" /]
[/gallery_list]
Although the gallery_list shortcode can also be used for this purpose:
[gallery_list col_num="3"]
[query posts_per_page="15" /]
[/gallery_list]
but the post list shortcodes provide more options.
They allows you to add a pagination and browsing filters to the list, while the gallery_list shortcode does not.
[post_list col_num="3"]
[query posts_per_page="15" /]
[/post_list]
[gallery_list col_num="3" galleries="gallery1"]
[query posts_per_page="15" /]
[/gallery_list]