More often than not, my blog posts are all scheduled to go live a number of days in advance. Indeed this particular post was finished 3 weeks before it actually went live.
Whilst this post does not include a YouTube video, sometimes you want to. So how do you schedule a Youtube video to go live at the same time as your blog post.
Well that part is easy enough, you do it when you’re first uploading the video, but what about the embed code? You can’t view the video in a standard YouTube page that’s already live, so how on earth do you get the embed code you need for your blog post so they can all go live at the same time.
With a little bit of faffing about it’s possible.
The trick is to grab the html code from an already live video.
For example. below is my Gatecrasher Classical video embedded into this page
The actual code for the embedded video is as follows:
<iframe width="560" height="315" src="https://www.youtube.com/embed/nbx5-MTdfOo" frameborder="0"
allow="autoplay; encrypted-media" allowfullscreen></iframe>
See the youtube.com/embed/nbx5-MTdfOo bit
That’s the important bit.
When you upload a new video to Youtube and schedule it to go live at the same time as your new blog post you’ll be given a URL on the left hand side, as seen in the below picture
So basically, copy and paste the embed code from a previous video, such as the Gatecrasher Classical one, as seen in the code above, remove the nbx5-MTdfOo bit and replace it with Up7HsWv66KU as seen in the image above.
Now you can embed the new video into your scheduled blog post and both the video and the post will go live at the same time, and your embed code will also work. Go ahead and try it, you will be able to preview your blog post with the embed code all working.