Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
420 views
in Technique[技术] by (71.8m points)

How to embed new Youtube's live video permanent URL?

I stream live on youtube a lot and since yesterday I experience a weird thing:

I embedded the livestream URL in my site. it was youtube.com/embed/ABCDE (normal embed link). That link used to show the current livestream and not a specific video. for example:

I'm streaming and you can watch it on youtube.com/embed/ABCDE. When i'm finished, the video gets its own url, something like youtube.com/watch?v=FGHIJ. In the next time I will stream, users can watch the stream on youtube.com/embed/ABCDE (that was a permanent url that didn't change).

Now, every time I stream, the livestream get its own link at first place, which means I have to update my embed code manually every time I stream.

I researched a bit around Google, SO and YouTube and I found out that a livestream's permanent url is youtube.com/channel/CHANNEL_ID/live. It's awesome and all, but I can't find a way to embed it.

(I use wordpress and I didn't find any plugin to do it automatically for me).

TL:DR; how to embed the livestream in the page youtube.com/channel/CHANNEL_ID/live?

question from:https://stackoverflow.com/questions/39275889/how-to-embed-new-youtubes-live-video-permanent-url

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

The embed URL for a channel's live stream is:

https://www.youtube.com/embed/live_stream?channel=CHANNEL_ID

You can find your CHANNEL_ID at https://www.youtube.com/account_advanced


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...