T
T
Tima2015-11-11 20:00:43
css
Tima, 2015-11-11 20:00:43

How to create your own browser player using html, css, js?

Good day to all. I wanted to know at least how and what to start from in order to write my own cross-browser player? Literature, forums, personal experience, whatever. Glad for any information. Thanks in advance :)

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Daniel Skripnik, 2015-11-11
@blackPeanut

You have html5 audio/video tags.
These tags are processed by JS commands.
You create arbitrary controls for the player (audio/video) and process those controls with available commands.
https://developer.mozilla.org/en-US/docs/Web/Guide...
For example, you create a video with a <video>src</video> tag
AND a pink button. The video should play when you click on the pink button.

var video = document.getElementsByTagName("video")[0],
      pinkPlay = document.getElemensByTagName("button")[0];

pinkPlay.addEventListener("click", function() {
  video.play();
}, false);

In a similar way, you can set up a custom player with other necessary parameters.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question