When watching a video, its possible to enter developer mode in the browser and enter the following command in the console to change the playback speed of a video
document.getElementsByTagName('video')[0].playbackRate = 0.9
When I try however to code this in html I am unable to access the video object.
var obj = document.getElementsByTagName('video');
console.log(obj);
returns an object of length 0
also trying
var player1 = document.getElementById("video");
console.log(player1);
player1.playbackRate = 2;
returns null
A demo of the not working code so far is here: https://jsbin.com/peludojisi/1/edit?html,js,console,output
Can someone please help me figure out how to set the playbackRate from html
many thanks in advance
Jesse