{"id":1822107,"date":"2020-10-23T15:26:03","date_gmt":"2020-10-23T15:26:03","guid":{"rendered":"https:\/\/toolset.com\/?post_type=course-lesson&#038;p=1822107"},"modified":"2020-10-26T09:55:57","modified_gmt":"2020-10-26T09:55:57","slug":"youtube-videos-with-advanced-options","status":"publish","type":"course-lesson","link":"https:\/\/toolset.com\/es\/course-lesson\/youtube-videos-with-advanced-options\/","title":{"rendered":"YouTube Videos with Advanced Options"},"content":{"rendered":"\n<p>To display a YouTube video insert the <a href=\"https:\/\/toolset.com\/block-item\/youtube\/\">Toolset YouTube<\/a> block. <\/p>\n\n\n\n<p>As soon as you insert the block, it asks you if you want to use a dynamic source or not. Choose &#8216;yes&#8217; to set the video to come from a custom field or &#8216;no&#8217; to select a specific video in the block.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Displaying a specific YouTube video<\/h2>\n\n\n\n<p>After inserting the Toolset YouTube block and clicking <strong>No<\/strong>, enter the URL of the video and click <strong>Embed<\/strong>.<\/p>\n\n\n\n<p>The video preview will show in the editor. Use the <strong>Video Settings <\/strong>section in the right sidebar to set custom display options. You can adjust settings like Width, Aspect Ratio, Start\/End Position, Autoplay, and more.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\" tb-image tb-image-media aligncenter\" data-toolset-blocks-image=\"b951d7454fb02f86354fb43b8a5c8407\"><a href=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-youtube-block-display-options.png\"><img decoding=\"async\" width=\"805\" height=\"504\" loading=\"lazy\" src=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-youtube-block-display-options-805x504.png\" alt=\"\" class=\"wp-image-1822595\" srcset=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-youtube-block-display-options-805x504.png 805w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-youtube-block-display-options-300x188.png 300w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-youtube-block-display-options-1024x642.png 1024w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-youtube-block-display-options-150x94.png 150w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-youtube-block-display-options-768x481.png 768w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-youtube-block-display-options.png 1200w\" sizes=\"auto, (max-width: 805px) 100vw, 805px\" \/><\/a><div class=\"tb-image-caption\"><figcaption>Toolset YouTube block offers many video settings that are not available with the core block<\/figcaption><\/div><\/figure>\n<\/div>\n\n\n<h2 class=\"wp-block-heading\">Displaying a video with URL coming from a custom field<\/h2>\n\n\n\n<p>In your <a href=\"https:\/\/toolset.com\/es\/glossary\/template\/\">single-post templates<\/a>, <a href=\"https:\/\/toolset.com\/es\/glossary\/archive\/\">archives<\/a> and <a href=\"https:\/\/toolset.com\/es\/glossary\/view\/\">custom lists of posts<\/a>, you can display videos whose URL comes from a custom field.<\/p>\n\n\n\n<div class=\"wp-block-toolset-blocks-grid tb-grid\" data-toolset-blocks-grid=\"db39e09b73fb7c34405f68a3f436697b\">\n<div class=\"wp-block-toolset-blocks-grid-column tb-grid-column tb-grid-align-top\" data-toolset-blocks-grid-column=\"3034fbe886c11054e95b46b09d3e4112\">\n<p><strong>Post with a custom field for the YouTube video URL<\/strong><\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-toolset-blocks-grid-column tb-grid-column tb-grid-align-top\" data-toolset-blocks-grid-column=\"3034fbe886c11054e95b46b09d3e4112\">\n<p><strong>YouTube video displayed dynamically on the single-post page<\/strong><\/p>\n<\/div>\n\n\n\n<div class=\"wp-block-toolset-blocks-grid-column tb-grid-column tb-grid-align-top\" data-toolset-blocks-grid-column=\"da95b0496445fa22d3f222b22209ca83\">\n<figure class=\"wp-block-image tb-image tb-image-media\" data-toolset-blocks-image=\"dd9b4d7813bfb4842ecd547b7abcabc7\"><a href=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-post-with-custom-field-for-youtube-url.png\"><img decoding=\"async\" width=\"1008\" height=\"615\" loading=\"lazy\" src=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-post-with-custom-field-for-youtube-url.png\" alt=\"\" class=\"wp-image-1822619\" srcset=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-post-with-custom-field-for-youtube-url.png 1008w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-post-with-custom-field-for-youtube-url-300x183.png 300w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-post-with-custom-field-for-youtube-url-150x92.png 150w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-post-with-custom-field-for-youtube-url-768x469.png 768w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-post-with-custom-field-for-youtube-url-805x491.png 805w\" sizes=\"auto, (max-width: 1008px) 100vw, 1008px\" \/><\/a><\/figure>\n<\/div>\n\n\n\n<div class=\"wp-block-toolset-blocks-grid-column tb-grid-column tb-grid-align-top\" data-toolset-blocks-grid-column=\"3034fbe886c11054e95b46b09d3e4112\">\n<figure class=\"wp-block-image tb-image tb-image-media\" data-toolset-blocks-image=\"526e473176511cd47b9bd2d88e20dfbc\"><a href=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-template-displaying-youtube-video-from-custom-field.png\"><img decoding=\"async\" width=\"1190\" height=\"1082\" loading=\"lazy\" src=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-template-displaying-youtube-video-from-custom-field.png\" alt=\"\" class=\"wp-image-1822627\" srcset=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-template-displaying-youtube-video-from-custom-field.png 1190w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-template-displaying-youtube-video-from-custom-field-300x273.png 300w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-template-displaying-youtube-video-from-custom-field-1024x931.png 1024w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-template-displaying-youtube-video-from-custom-field-150x136.png 150w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-template-displaying-youtube-video-from-custom-field-768x698.png 768w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/10\/toolset-template-displaying-youtube-video-from-custom-field-572x520.png 572w\" sizes=\"auto, (max-width: 1190px) 100vw, 1190px\" \/><\/a><\/figure>\n<\/div>\n<\/div>\n\n\n\n<p>After inserting the Toolset YouTube block and clicking <strong>Yes<\/strong>, you only need to select a custom field that holds the YouTube URL.<\/p>\n\n\n\n<p>A preview loads and you can now set the advanced options in the <strong>Video Settings <\/strong>section.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\" tb-image tb-image-media aligncenter\" data-toolset-blocks-image=\"e00833d10c06b281ba73e2db78c01a96\"><a href=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/06\/toolset-youtube-block-from-custom-field.png\"><img decoding=\"async\" width=\"705\" height=\"520\" loading=\"lazy\" src=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/06\/toolset-youtube-block-from-custom-field-705x520.png\" alt=\"Using Toolset YouTube block to display a video coming from a URL saved in a custom field\" class=\"wp-image-1822079\" srcset=\"https:\/\/toolset.com\/wp-content\/uploads\/2020\/06\/toolset-youtube-block-from-custom-field-705x520.png 705w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/06\/toolset-youtube-block-from-custom-field-300x221.png 300w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/06\/toolset-youtube-block-from-custom-field-1024x755.png 1024w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/06\/toolset-youtube-block-from-custom-field-150x111.png 150w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/06\/toolset-youtube-block-from-custom-field-768x567.png 768w, https:\/\/toolset.com\/wp-content\/uploads\/2020\/06\/toolset-youtube-block-from-custom-field.png 1132w\" sizes=\"auto, (max-width: 705px) 100vw, 705px\" \/><\/a><div class=\"tb-image-caption\"><figcaption>Single-post template using a Toolset YouTube to display videos with URL coming from a custom field<\/figcaption><\/div><\/figure>\n<\/div>","protected":false},"author":4341,"featured_media":1822667,"template":"","related-lesson":[8417,8427],"class_list":["post-1822107","course-lesson","type-course-lesson","status-publish","has-post-thumbnail","hentry","related-lesson-designing","related-lesson-post-templates"],"_links":{"self":[{"href":"https:\/\/toolset.com\/es\/wp-json\/wp\/v2\/course-lesson\/1822107","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/toolset.com\/es\/wp-json\/wp\/v2\/course-lesson"}],"about":[{"href":"https:\/\/toolset.com\/es\/wp-json\/wp\/v2\/types\/course-lesson"}],"author":[{"embeddable":true,"href":"https:\/\/toolset.com\/es\/wp-json\/wp\/v2\/users\/4341"}],"version-history":[{"count":8,"href":"https:\/\/toolset.com\/es\/wp-json\/wp\/v2\/course-lesson\/1822107\/revisions"}],"predecessor-version":[{"id":1823717,"href":"https:\/\/toolset.com\/es\/wp-json\/wp\/v2\/course-lesson\/1822107\/revisions\/1823717"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/toolset.com\/es\/wp-json\/wp\/v2\/media\/1822667"}],"wp:attachment":[{"href":"https:\/\/toolset.com\/es\/wp-json\/wp\/v2\/media?parent=1822107"}],"wp:term":[{"taxonomy":"related-lesson","embeddable":true,"href":"https:\/\/toolset.com\/es\/wp-json\/wp\/v2\/related-lesson?post=1822107"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}