Name is required.
Email address is required.
Invalid email address
Answer is required.
Exceeding max length of 5KB

Can't start MP4 video at 10 seconds in iOS using default play button


We have the MP4 video autostarting at 10 seconds everywhere except iOS using this code...

jwplayer().onPlay(function() {
jwplayer().seek(10);
}
});

In iOS we know autostart does not work. But after the video loads, when we hit the default play button (the one in the video) the video starts at 0 and not 10. Shouldn't the above code make it start at 10?

I'm hoping it's something very simple. Logic says this code should work.

4 Community Answers

Ethan Feldman

JW Player Support Agent  
0 rated :

Do you have an example?

JW Player

User  
0 rated :

Sure, here's a simple example. You may use any video path for "file". If you have an email, I can send you a private link.

<script language="JavaScript" type="text/javascript">
jwplayer().setup({
flashplayer: "http://...",
file: "http://...",
height: 240,
width: 320,
id: "mpl",
name: "mpl",
quality: "high",
version: "9.0.0",
autostart: "true",
allowfullscreen: "true",
allowscriptaccess: "always",
menu: "true",
wmode: "opaque",
flashvars: "icons=false&controlbar=bottom"
});

// Start initial playback at 10 seconds for autostart or manual start at 10 seconds for mobile devices.
jwplayer().onPlay(function() {
jwplayer().seek(10);
});

</script>

JW Player

User  
0 rated :

No info? Seems like this would be a popular issue. Even this code doesn't work...

firsttime = true;
jwplayer().onTime(function(event) {
if((event.position > 0) && (firsttime)){
jwplayer().seek(10);
firsttime = false;
}
});

Ethan Feldman

JW Player Support Agent  
0 rated :

Email me so I can look – ethan [at] jwplayer [dot] com

This question has received the maximum number of answers.