Videospeed Changer
by Thunderbolt
HTML
<a href="javascript:
(function() {
var myNode = document.getElementById('player-container');
while (myNode.firstChild) {
myNode.removeChild(myNode.firstChild);
}
var div = document.createElement('div');
div.setAttribute('id','plyr-player');
div.setAttribute('data-plyr-provider','youtube');
div.setAttribute('data-plyr-embed-id',document.getElementsByTagName('ytd-watch')[0].getAttribute('video-id'));
document.getElementById('player-container').appendChild(div);
var style = document.createElement('link');
style.href = 'https://cdn.plyr.io/3.0.6/plyr.css';
style.type = 'text/css';
style.rel = 'stylesheet';
document.head.appendChild(style);
var script = document.createElement('script');
script.onload = function () {
const player = new Plyr('#plyr-player');
};
script.src = 'https://cdn.plyr.io/3.0.6/plyr.js';
document.head.appendChild(script);
})();">
Plyr YouTube Video Player</a>
CSS
a {
display: block;
height: 7em;
width: 300px;
line-height: 6em;
background-color: #080000;
text-decoration: none;
color: #FFFFFF;
text-align: center;
}
a:after{
content: "Ziehe mich in deine Lesezeichenleiste!";
position: absolute;
margin-left: -200px;
width: 300px;
margin-top: 1em;
text-align: center;
color: #FFFFFF;
}