I am trying to create a new HTML5 video elemnt entirely throught JS. So I try to do it the same way I create a new image, like: obj = new Image() I write obj = new HTMLVideoElement(). However this doesn’t work. I get the runtime error: Object doesn’t support this action.
What is wrong? Thanks.
I am trying to create a new HTML5 video elemnt entirely throught JS. So
Share
The
Imageclass is a special case.The standard way to create any arbitrary HTML element is this: