{"id":115,"date":"2019-01-28T21:29:47","date_gmt":"2019-01-28T21:29:47","guid":{"rendered":"https:\/\/www.publicalbum.org\/blog\/?p=115"},"modified":"2020-08-25T06:55:56","modified_gmt":"2020-08-25T06:55:56","slug":"embed-photos-slideshow-carousel-widget","status":"publish","type":"post","link":"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget","title":{"rendered":"Embed photos as a slideshow with carousel widget"},"content":{"rendered":"<p>After a pause when I only improved the existing tool, I represent a new component for you that is meant to embed a photos album to a website. It is a <strong>carousel widget<\/strong> that is also the basis part of the new component of the gallery, which I will describing in some another post.<\/p>\n<p><script src=\"https:\/\/cdn.jsdelivr.net\/npm\/publicalbum@latest\/embed-ui.min.js\" async=\"\"><\/script><\/p>\n<div class=\"pa-carousel-widget\" style=\"width: 100%; height: 480px; xdisplay: none;\" data-link=\"https:\/\/photos.app.goo.gl\/CSV7NDstShTUwUZq5\" data-title=\"Mr. Monstro\" data-description=\"Mr. Monstro is a great traveler. He visited Madeira, Poland, but also Georgia, Italy ...\"><img alt=\"\" data-src=\"https:\/\/lh3.googleusercontent.com\/XlH6wo2PzrAEqmplYrZwV0fI-2TafTT6BRwZhKDfZSHd_zT7HIdPyPWd3Xuqhn1QQADuTJ32QFmcgYiTOEU0sC4Bvf-VyTIiq-DxxEaxIeWDYyUK_VjaW8-zrMGBvekDZT77lpduYQ=w640-h480\"><br><img alt=\"\" data-src=\"https:\/\/lh3.googleusercontent.com\/HISe-DV_b4gjLvSEGzrJlsqBU2rSE8uQpSqHHKTPihg_Ax9VtfCrOrvdXF01raBeBleAWQKI7Hfb4_w9vZeJKFymQfNTlubwXxTBTbqGTPwjg7S0CBtQsQJqsspvIhD9c-pniSZrEw=w640-h480\"><br><img alt=\"\" data-src=\"https:\/\/lh3.googleusercontent.com\/05lhR1IAQY_B9rdQ_GvHDNLe1lJsSPyyuDeIMkt--gDDAnO2_EATwif7-sfNd2K_48RvyqKmN-u2svKZ06yfh8bnrbQ5kBUrIHfZvWheTzDGhIeFd1roPor-F_BycJmVKbQO6a9EaA=w640-h480\"><\/div>\n<p><small>Carousel widget demo with my favorite Mr. Monstro.<\/small><\/p>\n<p><!--more--><\/p>\n<h3>Why a new slideshow widget for website?<\/h3>\n<p>You write me many good things and suggestions for improvement. That&#8217;s why I decided to create a completely new type of galley widget. This <strong>carousel widget<\/strong> uses part of the completely <strong>new gallery component<\/strong> whitch I&#8217;m preparing. And because some features are already available, I want to share it with you to also use it.<\/p>\n<h3>For whom is a component designed for?<\/h3>\n<p>The Carousel component is for everyone who wants to show photos on your site as a graphic add-on or slide show showing your photos on the site.<\/p>\n<p>Carousel widget not contains any additional features such as fullpage or fullscreen mode. Included simply switching forward and back and automatically playing back.<\/p>\n<h2>How to correctly insert a carousel widget into website?<\/h2>\n<p>There are many ways to do this. I will describe <strong>two basic ones here<\/strong>. The first is probably the easiest one for you.<\/p>\n<h6>1) Embed carousel slideshow with Google photos album.<\/h6>\n<p>You can use the same tool as generating <a href=\"https:\/\/www.publicalbum.org\/blog\/embedding-google-photos-albums\">code for embed from google photos album<\/a>. You can generate the html code using a new feature called &#8220;<strong>carousel only<\/strong>&#8220;. So, there is a certain <strong>advantage of combining Google Photos albums with the generated carousel code<\/strong>.<\/p>\n<p>To generate the code you will need a link of <strong>Google photos shared album<\/strong>&nbsp;like this:&nbsp;<code>https:\/\/photos.app.goo.gl\/somehash<\/code>. Paste the shared link into the following form and press the &#8220;<strong>Create embed code<\/strong>&#8221; button. Next, setup parameters and paste the resulting code into your website.<\/p>\n\n\n<script>window['defaultIsCarousel'] = true;<\/script>\n\n\n<div id=\"webapp__embed-player\" class=\"reactapp\"><\/div>\n\n\n<h6>2) Insert the script with the carousel widget manually<\/h6>\n<p>The base is an html code containing information about the carousel widget setting. It is decorated with javascript, which creates the widget in place of the embedded code.<\/p>\n<p>Code example to insert into website:<\/p>\n<pre>&lt;<strong>script<\/strong> src=\"\/link\/to\/embed-ui.min.js\" async&gt;&lt;\/<strong>script<\/strong>&gt;\n&lt;<strong>div<\/strong> <strong>class<\/strong>=\"pa-carousel-widget\"\n<strong>  style<\/strong>=\"width: 100%; height: 480px; display: none;\"\n<strong>  data-link<\/strong>=\"https:\/\/photos.app.goo.gl\/CSV7NDstShTUwUZq5\"\n<strong>  data-title<\/strong>=\"Mr. Monstro\"&gt;\n    &lt;<strong>img<\/strong> <strong>data-src<\/strong>=\"https:\/\/...image1.jpg\" \/&gt;\n    &lt;<strong>img<\/strong> <strong>data-src<\/strong>=\"https:\/\/...image2.jpg\" \/&gt;\n    &lt;<strong>img<\/strong> <strong>data-src<\/strong>=\"https:\/\/...image3.jpg\" \/&gt;\n&lt;\/<strong>div<\/strong>&gt;<\/pre>\n<p>First of all, you need a decorator. Put it in front of the code or at the end of the page, but also in the header element. Choose the best solution for you. The complete content of the script element is as follows:<\/p>\n<pre>&lt;<strong>script<\/strong> src=\"https:\/\/cdn.jsdelivr.net\/npm\/publicalbum@latest\/embed-ui.min.js\" async&gt;&lt;\/<strong>script<\/strong>&gt;<\/pre>\n<h6>The <code>div<\/code> container contains several attributes.<\/h6>\n<ul>\n<li><code><strong>class<\/strong><\/code> &#8211; Class is the main identification that it is a carousel.<\/li>\n<li><code><strong>style<\/strong><\/code> &#8211; Style is helpful. The widget will be hidden until it is decorated.<br>It also allows you to <strong>adjust the dimensions<\/strong>.<\/li>\n<li><code><strong>data-link<\/strong><\/code>&nbsp;&#8211; Album link, or website, if available.<\/li>\n<li><code><strong>data-title<\/strong><\/code> &#8211; Caption of the carousel.<\/li>\n<li><code><strong>data-delay<\/strong><\/code> &#8211; Delay between frames in seconds.<\/li>\n<li><code><strong>data-autorepeat<\/strong><\/code> &#8211; Repeat all the time.<\/li>\n<li><code><strong>data-background-color<\/strong><\/code> &#8211; This is a hexadecimal code of color for background color setup. The default is <code>#000000<\/code>(black).<\/li>\n<\/ul>\n<h6>The <code>img<\/code> element contains the following:<\/h6>\n<ul>\n<li><code><strong>src<\/strong><\/code> &#8211; Empty default attribute if necessery.<\/li>\n<li><code><strong>alt<\/strong><\/code> &#8211; Same as <code>src<\/code>.<\/li>\n<li><code><strong>data-src<\/strong><\/code>&nbsp;&#8211; Absolute or relative url to real fullsize image.<\/li>\n<li><code><strong>data-initial-src<\/strong><\/code> &#8211; If you have a thumbnail, you can put it in to this.<\/li>\n<li><code><strong>data-width<\/strong><\/code> &#8211; If you need setup diferent width of image, you may set it manualy.<\/li>\n<li><code><strong>data-height<\/strong><\/code> &#8211; This option is a similar as previouse.<\/li>\n<li><code><strong>data-stretch<\/strong><\/code> &#8211; Enable or disable image stretch.<\/li>\n<li><code><strong>data-enlarge<\/strong><\/code> &#8211; Enable or disable image enlarge.<\/li>\n<\/ul>\n<p><em>Some settings may not be stable. I will be glad for your comments and ideas.<\/em><\/p>","protected":false},"excerpt":{"rendered":"<p>After a pause when I only improved the existing tool, I represent a new component for you that is meant to embed a photos album to a website. It is a carousel widget that is also the basis part of the new component of the gallery, which I will describing in some another post. Carousel &hellip; <a href=\"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Embed photos as a slideshow with carousel widget&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[],"class_list":["post-115","post","type-post","status-publish","format-standard","hentry","category-google-photos"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v23.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Embed photos as a slideshow with carousel widget - Public album .org<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Embed photos as a slideshow with carousel widget - Public album .org\" \/>\n<meta property=\"og:description\" content=\"After a pause when I only improved the existing tool, I represent a new component for you that is meant to embed a photos album to a website. It is a carousel widget that is also the basis part of the new component of the gallery, which I will describing in some another post. Carousel &hellip; Continue reading &quot;Embed photos as a slideshow with carousel widget&quot;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget\" \/>\n<meta property=\"og:site_name\" content=\"Public album .org\" \/>\n<meta property=\"article:published_time\" content=\"2019-01-28T21:29:47+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2020-08-25T06:55:56+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/lh3.googleusercontent.com\/XlH6wo2PzrAEqmplYrZwV0fI-2TafTT6BRwZhKDfZSHd_zT7HIdPyPWd3Xuqhn1QQADuTJ32QFmcgYiTOEU0sC4Bvf-VyTIiq-DxxEaxIeWDYyUK_VjaW8-zrMGBvekDZT77lpduYQ=w640-h480\" \/>\n<meta name=\"author\" content=\"Pavex\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Pavex\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget\",\"url\":\"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget\",\"name\":\"Embed photos as a slideshow with carousel widget - Public album .org\",\"isPartOf\":{\"@id\":\"https:\/\/www.publicalbum.org\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget#primaryimage\"},\"thumbnailUrl\":\"https:\/\/lh3.googleusercontent.com\/XlH6wo2PzrAEqmplYrZwV0fI-2TafTT6BRwZhKDfZSHd_zT7HIdPyPWd3Xuqhn1QQADuTJ32QFmcgYiTOEU0sC4Bvf-VyTIiq-DxxEaxIeWDYyUK_VjaW8-zrMGBvekDZT77lpduYQ=w640-h480\",\"datePublished\":\"2019-01-28T21:29:47+00:00\",\"dateModified\":\"2020-08-25T06:55:56+00:00\",\"author\":{\"@id\":\"https:\/\/www.publicalbum.org\/blog\/#\/schema\/person\/1415f3e82b03ca14f8aa2f18468a5b87\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget#primaryimage\",\"url\":\"https:\/\/lh3.googleusercontent.com\/XlH6wo2PzrAEqmplYrZwV0fI-2TafTT6BRwZhKDfZSHd_zT7HIdPyPWd3Xuqhn1QQADuTJ32QFmcgYiTOEU0sC4Bvf-VyTIiq-DxxEaxIeWDYyUK_VjaW8-zrMGBvekDZT77lpduYQ=w640-h480\",\"contentUrl\":\"https:\/\/lh3.googleusercontent.com\/XlH6wo2PzrAEqmplYrZwV0fI-2TafTT6BRwZhKDfZSHd_zT7HIdPyPWd3Xuqhn1QQADuTJ32QFmcgYiTOEU0sC4Bvf-VyTIiq-DxxEaxIeWDYyUK_VjaW8-zrMGBvekDZT77lpduYQ=w640-h480\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.publicalbum.org\/blog\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Embed photos as a slideshow with carousel widget\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.publicalbum.org\/blog\/#website\",\"url\":\"https:\/\/www.publicalbum.org\/blog\/\",\"name\":\"Public album .org\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.publicalbum.org\/blog\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.publicalbum.org\/blog\/#\/schema\/person\/1415f3e82b03ca14f8aa2f18468a5b87\",\"name\":\"Pavex\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.publicalbum.org\/blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/e47c6671479e0609362ab70337cfac20?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/e47c6671479e0609362ab70337cfac20?s=96&d=mm&r=g\",\"caption\":\"Pavex\"},\"url\":\"https:\/\/www.publicalbum.org\/blog\/author\/pavex\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Embed photos as a slideshow with carousel widget - Public album .org","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget","og_locale":"en_US","og_type":"article","og_title":"Embed photos as a slideshow with carousel widget - Public album .org","og_description":"After a pause when I only improved the existing tool, I represent a new component for you that is meant to embed a photos album to a website. It is a carousel widget that is also the basis part of the new component of the gallery, which I will describing in some another post. Carousel &hellip; Continue reading \"Embed photos as a slideshow with carousel widget\"","og_url":"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget","og_site_name":"Public album .org","article_published_time":"2019-01-28T21:29:47+00:00","article_modified_time":"2020-08-25T06:55:56+00:00","og_image":[{"url":"https:\/\/lh3.googleusercontent.com\/XlH6wo2PzrAEqmplYrZwV0fI-2TafTT6BRwZhKDfZSHd_zT7HIdPyPWd3Xuqhn1QQADuTJ32QFmcgYiTOEU0sC4Bvf-VyTIiq-DxxEaxIeWDYyUK_VjaW8-zrMGBvekDZT77lpduYQ=w640-h480"}],"author":"Pavex","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Pavex","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget","url":"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget","name":"Embed photos as a slideshow with carousel widget - Public album .org","isPartOf":{"@id":"https:\/\/www.publicalbum.org\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget#primaryimage"},"image":{"@id":"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget#primaryimage"},"thumbnailUrl":"https:\/\/lh3.googleusercontent.com\/XlH6wo2PzrAEqmplYrZwV0fI-2TafTT6BRwZhKDfZSHd_zT7HIdPyPWd3Xuqhn1QQADuTJ32QFmcgYiTOEU0sC4Bvf-VyTIiq-DxxEaxIeWDYyUK_VjaW8-zrMGBvekDZT77lpduYQ=w640-h480","datePublished":"2019-01-28T21:29:47+00:00","dateModified":"2020-08-25T06:55:56+00:00","author":{"@id":"https:\/\/www.publicalbum.org\/blog\/#\/schema\/person\/1415f3e82b03ca14f8aa2f18468a5b87"},"breadcrumb":{"@id":"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget#primaryimage","url":"https:\/\/lh3.googleusercontent.com\/XlH6wo2PzrAEqmplYrZwV0fI-2TafTT6BRwZhKDfZSHd_zT7HIdPyPWd3Xuqhn1QQADuTJ32QFmcgYiTOEU0sC4Bvf-VyTIiq-DxxEaxIeWDYyUK_VjaW8-zrMGBvekDZT77lpduYQ=w640-h480","contentUrl":"https:\/\/lh3.googleusercontent.com\/XlH6wo2PzrAEqmplYrZwV0fI-2TafTT6BRwZhKDfZSHd_zT7HIdPyPWd3Xuqhn1QQADuTJ32QFmcgYiTOEU0sC4Bvf-VyTIiq-DxxEaxIeWDYyUK_VjaW8-zrMGBvekDZT77lpduYQ=w640-h480"},{"@type":"BreadcrumbList","@id":"https:\/\/www.publicalbum.org\/blog\/embed-photos-slideshow-carousel-widget#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.publicalbum.org\/blog"},{"@type":"ListItem","position":2,"name":"Embed photos as a slideshow with carousel widget"}]},{"@type":"WebSite","@id":"https:\/\/www.publicalbum.org\/blog\/#website","url":"https:\/\/www.publicalbum.org\/blog\/","name":"Public album .org","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.publicalbum.org\/blog\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.publicalbum.org\/blog\/#\/schema\/person\/1415f3e82b03ca14f8aa2f18468a5b87","name":"Pavex","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.publicalbum.org\/blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/e47c6671479e0609362ab70337cfac20?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/e47c6671479e0609362ab70337cfac20?s=96&d=mm&r=g","caption":"Pavex"},"url":"https:\/\/www.publicalbum.org\/blog\/author\/pavex"}]}},"_links":{"self":[{"href":"https:\/\/www.publicalbum.org\/blog\/wp-json\/wp\/v2\/posts\/115"}],"collection":[{"href":"https:\/\/www.publicalbum.org\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.publicalbum.org\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.publicalbum.org\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.publicalbum.org\/blog\/wp-json\/wp\/v2\/comments?post=115"}],"version-history":[{"count":34,"href":"https:\/\/www.publicalbum.org\/blog\/wp-json\/wp\/v2\/posts\/115\/revisions"}],"predecessor-version":[{"id":912,"href":"https:\/\/www.publicalbum.org\/blog\/wp-json\/wp\/v2\/posts\/115\/revisions\/912"}],"wp:attachment":[{"href":"https:\/\/www.publicalbum.org\/blog\/wp-json\/wp\/v2\/media?parent=115"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.publicalbum.org\/blog\/wp-json\/wp\/v2\/categories?post=115"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.publicalbum.org\/blog\/wp-json\/wp\/v2\/tags?post=115"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}