How can I remove the watch later and share buttons from youtube iframe embed player. Using the following embed code for embedding video clips.
The only way to do it is to create a negative margin at the top of a container which has overflow
set to hidden
. See my CodePen here.
CSS:
.videoWrapper {
overflow: hidden;
}
@media (min-width: 1500px) {
.videoWrapper {
margin-top: -135px;
}
}
@media (min-width: 1200px) {
.videoWrapper {
margin-top: -75px;
}
}
HTML:
But then of course you lose the top of your video. You may also be breaching some of part of YouTube's Terms of Service.
Also, this tends to only work well at browser widths above 1200px. Below this the title and top controls take up a much larger percentage of player real estate, so you would lose too much off the top of your video.