Solved

How to jump to a video time using javascript

Posted on 2012-04-04
5
229 Views
Last Modified: 2014-09-07
I'm playing a video on a webpage and I'd like to be able to click on a link/button that will jump the video to that time.

ie: I click on a link that references something 2min into the video, I'd like the video to jump to the 2min mark.

I've seen things for html 5 but I can't seem to get them working.

I've tried using the <embed> and <objects> tags as well as <video>.
0
Comment
Question by:JPClaude
  • 2
5 Comments
 
LVL 75

Accepted Solution

by:
Michel Plungjan earned 500 total points
ID: 37809663
Something like

<a href="http://youtu.be/MEkS_mQ0GlI?t=2m00s" onclick="document.getElementById('video').src=this.href; return false">2:00</a>
0
 

Author Comment

by:JPClaude
ID: 37813205
Exactly. My boss wants to do something like that for a project and until HTML 5 comes out, I'm not sure how to proceed.
0
 
LVL 75

Expert Comment

by:Michel Plungjan
ID: 37813244
I just showed you
Add the embed with an ID of video
0

Featured Post

Master Your Team's Linux and Cloud Stack!

The average business loses $13.5M per year to ineffective training (per 1,000 employees). Keep ahead of the competition and combine in-person quality with online cost and flexibility by training with Linux Academy.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Learn by example how to specify CSS selectors for Selenium WebDriver test automation software.
Although it can be difficult to imagine, someday your child will have a career of his or her own. He or she will likely start a family, buy a home and start having their own children. So, while being a kid is still extremely important, it’s also …
This tutorial walks through the best practices in adding a local business to Google Maps including how to properly search for duplicates, marker placement, and inputing business details. Login to your Google Account, then search for "Google Mapmaker…
Any person in technology especially those working for big companies should at least know about the basics of web accessibility. Believe it or not there are even laws in place that require businesses to provide such means for the disabled and aging p…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question