JavaScript Videojs : Getting timestamp of video dynamically

I am trying to implement a course portal where videos will be uploaded locally and will be available to students for studying. I am trying to create a interactive system: which will produce a question when the video reaches at a particular time.

For this I am using 'video-js' plugin for flash and HTML5 player. Now what I want to do is keeping track of time of video. Hence when the video reaches a particular time, I will be able to make a ajax call showing the question at particular time.

For this I am using 'durationchange' of video-js plugin. But it's only giving the 0th second as shown in following code

video1 = videojs('mplayer');
video1.on('durationchange', event);

var video1 = function(){

  currentTime = video1.currentTime; // nothing

}

How should I go about it. Please help me. Thanx.

Answer:1

I'm having trouble with validation of input type="date". It shouldn't accept 18 years old below. Could you please help me? Thank you. I google and search the forum I haven't found the answer. I ...

I'm having trouble with validation of input type="date". It shouldn't accept 18 years old below. Could you please help me? Thank you. I google and search the forum I haven't found the answer. I ...

  1. input type date format
  2. input type date html
  3. input type date value
  4. input type date default value
  5. input type date placeholder
  6. input type date css
  7. input type date safari
  8. input type date set value
  9. input type date time
  10. input type date not working in ie11
  11. input type date not working in ie
  12. input type date min today
  13. input type date polyfill
  14. input type date min max
  15. input type date react
  16. input type date set value jquery
  17. input type date onchange
  18. input type date range
  19. input type date validation
  20. input type date value format

I'm trying to get href value of a specific anchor tag placed on a html page. html tag structure <a rel="nofollow" title="some title" href="http://www.this-is-what-i-need.com/just-this.html">&...

I'm trying to get href value of a specific anchor tag placed on a html page. html tag structure <a rel="nofollow" title="some title" href="http://www.this-is-what-i-need.com/just-this.html">&...

I've added a click event to a parent #carousel-thumbs. carouselThumbsContainer.onclick = function(ev) { var target = ev.target; // which child was actually clicked } <ul id="carousel-...

I've added a click event to a parent #carousel-thumbs. carouselThumbsContainer.onclick = function(ev) { var target = ev.target; // which child was actually clicked } <ul id="carousel-...

  1. javascript index child
  2. javascript child index in parent
  3. javascript index of child element
  4. javascript index of child node
  5. javascript get child index
  6. javascript getchild index in parent
  7. javascript find child index
  8. javascript dom child index
  9. javascript set child index
  10. javascript get index of child element
  11. javascript get index of child node
  12. javascript dom get child index
  13. javascript find index of child element

Let's say we have a ball that can be moved left and right around the screen. When you click space, the ball should jump. I got the ball to move left and right in a canvas. However, when the ball is ...

Let's say we have a ball that can be moved left and right around the screen. When you click space, the ball should jump. I got the ball to move left and right in a canvas. However, when the ball is ...