Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

hide "more videos" within youtube iframe when stop video

Tags:

youtube

iframe

How to hide the "more videos" section in Youtube iframes, when the user stops the video?

Example:

<iframe width="750" height="420" src="https://www.youtube/embed/cZnsLVArIt8?rel=0&iv_load_policy=3" frameborder="0" allowfullscreen></iframe> 

enter image description here

I cant find any solution here.

like image 916
Krystian Avatar asked Oct 19 '18 07:10

Krystian


People also ask

How do you embed a YouTube video without showing any videos?

Option 1 – Using the YouTube Interface Deselect the first checkbox towards the bottom that says “Show suggested videos when the video finishes”. After deselecting this option you'll notice the embed code updates to allow for this new parameter. Now, simply copy the new embed code and drop it into your HTML.

Does Rel 0 still work?

YouTube changed the rel=0 parameter as of September 2018 so that it no longer fully disables related videos. However, you can work around this using the YouTube Player API to show custom HTML instead of related videos.


1 Answers

If you have uBlock Origin ad-blocker installed, here's the static filter to remove that:

!YouTube embed pause overlay youtube.com##.ytp-pause-overlay 
like image 139
Dogkiller87 Avatar answered Sep 28 '22 01:09

Dogkiller87