{"id":33965,"date":"2019-03-04T10:26:27","date_gmt":"2019-03-04T10:26:27","guid":{"rendered":"http:\/\/getshortcodes.com\/?post_type=docs&#038;p=33965"},"modified":"2020-10-21T13:39:38","modified_gmt":"2020-10-21T13:39:38","slug":"custom-gallery","status":"publish","type":"docs","link":"https:\/\/getshortcodes.com\/docs\/custom-gallery\/","title":{"rendered":"Custom Gallery"},"content":{"rendered":"<div class=\"block-demo block-demo-default\">\n\t<div class=\"block-demo-viewport\">\n\t\t<div class=\"su-custom-gallery su-custom-gallery-align-left su-custom-gallery-title-hover\">\n<div class=\"su-custom-gallery-slide\" style=\"width:120px;height:80px\"><a href=\"https:\/\/getshortcodes.com\/wp-content\/uploads\/2017\/08\/slider-image-1.jpg\" target=\"_blank\" title=\"Gallery image 1\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/getshortcodes.com\/wp-content\/uploads\/2017\/08\/slider-image-1-120x80.jpg\" alt=\"Gallery image 1\" width=\"120\" height=\"80\" \/><span class=\"su-custom-gallery-title\">Gallery image 1<\/span><\/a><\/div>\n<div class=\"su-custom-gallery-slide\" style=\"width:120px;height:80px\"><a href=\"https:\/\/getshortcodes.com\/wp-content\/uploads\/2017\/08\/slider-image-2.jpg\" target=\"_blank\" title=\"Gallery image 2\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/getshortcodes.com\/wp-content\/uploads\/2017\/08\/slider-image-2-120x80.jpg\" alt=\"Gallery image 2\" width=\"120\" height=\"80\" \/><span class=\"su-custom-gallery-title\">Gallery image 2<\/span><\/a><\/div>\n<div class=\"su-custom-gallery-slide\" style=\"width:120px;height:80px\"><a href=\"https:\/\/getshortcodes.com\/wp-content\/uploads\/2017\/08\/slider-image-3.jpg\" target=\"_blank\" title=\"Gallery image 3\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/getshortcodes.com\/wp-content\/uploads\/2017\/08\/slider-image-3-120x80.jpg\" alt=\"Gallery image 3\" width=\"120\" height=\"80\" \/><span class=\"su-custom-gallery-title\">Gallery image 3<\/span><\/a><\/div>\n<div class=\"su-clear\"><\/div>\n<\/div>\n\t<\/div>\n\t<div class=\"block-demo-source\">\n\t\t<pre contenteditable=\"true\"><\/pre>\n\t<\/div>\n<\/div>\n\n\n<p class=\"h2\">Table of contents<\/p>\n\n<ol><li><a href=\"#description\">Description<\/a><\/li><li><a href=\"#options\">Options<\/a><\/li><li><a href=\"#related-articles\">Related articles<\/a><\/li><\/ol><\/li><\/ol>\n\n\n<h2 class=\"wp-block-heading\" id=\"description\">Description<\/h2>\n\n\n\n<p>This shortcode allows you to easily create custom galleries.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"options\">Options<\/h2>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><th>Option name<\/th><th>Possible values<\/th><th>Default value<\/th><\/tr><tr><td><strong>source<\/strong><br>Choose images source. You can use images from Media library or retrieve it from posts (thumbnails) posted under specified blog category. You can also pick any custom taxonomy<\/td><td>media: 1,2,3 (Media file IDs)<br>posts: 1,2,3 (Post IDs)<br>posts: recent (Recent posts)<br>category: 1,2,3 (Category IDs)<br>taxonomy: book\/3,5 (Taxonomy term slug \/ term IDs)<\/td><td>none<\/td><\/tr><tr><td><strong>limit<\/strong><br>Maximum number of image source posts (for recent posts, category and custom taxonomy)<\/td><td>Number from -1 to 100<\/td><td>20<\/td><\/tr><tr><td><strong>link<\/strong><br>Select which links will be used for images in this gallery<\/td><td>none (None)<br>image (Full-size image)<br>lightbox (Lightbox)<br>custom (Slide link (added in media editor))<br>attachment (Attachment page)<br>post (Post permalink)<\/td><td>none<\/td><\/tr><tr><td><strong>target<\/strong><br>Open links in<\/td><td>self (Open in same tab)<br>blank (Open in new tab)<\/td><td>self<\/td><\/tr><tr><td><strong>width<\/strong><br>Single item width (in pixels)<\/td><td>Number from 10 to 1600<\/td><td>90<\/td><\/tr><tr><td><strong>height<\/strong><br>Single item height (in pixels)<\/td><td>Number from 10 to 1600<\/td><td>90<\/td><\/tr><tr><td><strong>title<\/strong><br>Title display mode<\/td><td>never (Never)<br>hover (On mouse over)<br>always (Always)<\/td><td>hover<\/td><\/tr><tr><td><strong>class<\/strong><br>Additional CSS class name(s) separated by space(s)<\/td><td>CSS class name(s) separated by space(s)<\/td><td><em>\u2013 none \u2013<\/em><\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p class=\"has-small-font-size\">Photos by <a rel=\"noreferrer noopener\" href=\"https:\/\/unsplash.com\/@visualworld\" target=\"_blank\">Matt Palmer<\/a><\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"related-articles\">Related articles<\/h2>\n\n\n\n<ul class=\"is-style-documents wp-block-list\"><li><a href=\"\/docs\/custom-links-in-image-carousel-and-custom-gallery-shortcodes\/\">How to add custom links to slides<\/a><\/li><\/ul>\n","protected":false},"featured_media":36653,"template":"","docs_category":[21],"class_list":["post-33965","docs","type-docs","status-publish","has-post-thumbnail","hentry","docs_category-shortcodes"],"_links":{"self":[{"href":"https:\/\/getshortcodes.com\/api\/wp\/v2\/docs\/33965","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/getshortcodes.com\/api\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/getshortcodes.com\/api\/wp\/v2\/types\/docs"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/getshortcodes.com\/api\/wp\/v2\/media\/36653"}],"wp:attachment":[{"href":"https:\/\/getshortcodes.com\/api\/wp\/v2\/media?parent=33965"}],"wp:term":[{"taxonomy":"docs_category","embeddable":true,"href":"https:\/\/getshortcodes.com\/api\/wp\/v2\/docs_category?post=33965"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}