Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

duration property of a video

Status
Not open for further replies.

breaststroke

Programmer
Apr 10, 2011
39
0
0
ES
Hi,

I am trying to figure out the following piece of code:

Code:
video = document.getElementById(""video"");
sap = video.duration / 4;
(sap > 20 ? console.log(""true"") : console.log(""false""));

I guess it talks about a video and its duration (in time).
Does it mean that it would display the word "true" (on the console) if a quarter of the video is longer than 20 (mts?), which would the same as to say that the duration of the video is longer than 80?

Thank you very much in advance!

enjoy practicing languages at:
 
yup, that's pretty much it. Though the use of double double quotes is sure to cause errors



----------------------------------
Phil AKA Vacunita
----------------------------------
Ignorance is not necessarily Bliss, case in point:
Unknown has caused an Unknown Error on Unknown and must be shutdown to prevent damage to Unknown.

Web & Tech
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top