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

HTML5 pseudo video streaming with Ruby on Rails won't work on Chrome


Hi.

I'm building web application serving MP4 videos with Ruby on Rails.

We've build custom control panel with using the JavaScript API of JW player and it works fine with Safari and Internet Explorer.

But on Chrome, only the seek function won't work correctly.
If I seek in already loaded part (ex. back 10 sec) video pauses and looping PALAYING and PAUSED status forever.
I thought it is because my application didn't handling the "206 partial content" request, but it seems the player didn't send the http request to server when seeking or looping status.

The seek function works fine with the JW Player's FLASH mode, but I need to change the playback speed with HTML5.
Also, if I use native video tag in Chrome, it seems sending HTTP request to server, but if I didn't use JW Player, I need to rebuild all function with using native HTML5 video tag.

Are there anyone succeeded to using seek function in HTML5 mode with Chrome?

The link to my web application. It is totally Japanese site. You can play video with clicking thumbnail.

https://manabito-online.com/course/detail/marketing-fundamentals

Thanks for taking time to read my question.

13 Community Answers

Ethan Feldman

JW Player Support Agent  
0 rated :

Hi,

How was this video encoded? – https://manabito-online.com/course/getvideo/0—marketing-fundamentals—635—720.mp4

If I use it here, it has issues too – http://www.jwplayer.com/wizard/

Best,
-Ethan

t...

User  
0 rated :

Ethan,

We are using Adobe premiere to encoding the video.

I tried with following URL and the video played fine, but if I try to seek, "Error loading media: File could not be played" occured.

https://manabito-online.com/course/getvideo/0--marketing-fundamentals--635--720.mp4

Is there any way to avoid this?

Ethan Feldman

JW Player Support Agent  
0 rated :

For me, it only plays for 1 second, before it has the replay icon on it. I would try to do a re encode using HandBrake. Use default settings + web optimized.

http://handbrake.fr/

t...

User  
0 rated :

Ethan,

I also get that problem.
When only plays 1 second, Chrome seems act as following.

1. Chrome get the video only 1 second (may be).
2. Chrome plays 1 second.
3. The video didn't have loaded any more.
4. Chrome stops and waiting for next part.

But in step4, Chrome ( or JW Player) doesn't send HTTP requests to server.

So, I think this is not because of the video.

Ethan Feldman

JW Player Support Agent  
0 rated :

Did you try the re encode first to test?

t...

User  
0 rated :

I have uploaded re encoded video to following URL, but the situation seems same.
If I tried to seek, the video stops.

https://manabito-online.com/course/getvideo/0--marketing-fundamentals--635--720.mp4

If I access to above URL directly, I can seek back and forth.
Namely, if I won't use JW Player, I can seek and if I used JW Player (even without my control panel), I can not seek.

This is why I thought this problem is caused by JW Player.

And more, if I access to the video directly (i.e. without JW Player), I can not seek back more than 10 seconds (EX. 20 sec to 10 sec).
But in this case, Chrome sending HTTP request. The log recorded in the server and request to server will be shown in Chrome's "network" tab.

If I use JW Player, Chrome won't send HTTP request.
No logs recorded in server nor Chrome's "network" tab.

Ethan Feldman

JW Player Support Agent  
0 rated :

I would do the following:

Link to – http://www.longtailvideo.com/jw/upload/bunny.mp4 as the file variable and see if the issues happen.

If so, then download it and host it on your server and see if it still works

that way you can determine if the issues is encoding or server based.

t...

User  
0 rated :

I made the testing environment to play your video. The URL is following.

http://133.242.178.39/user/list?&item_flag=0&part_id=635&course_id=24&chapter_id=187&play_type=0

The video can play but can not seek.
If I tried to seek, the player looping play and pause forever.
Moreover, I can not seek back. Only to forward.

Also, if I download the video and host on my server, the video can not play.

Is this because of my server's problem?

Ethan Feldman

JW Player Support Agent  
0 rated :

Yes, if it cannot work at all on your server, then there is an issue with the server.

t...

User  
0 rated :

If this is because of the server, why it is works on Internet Explorer and Safari?

Moreover, when the video stops, Chrome and JW Player won't send any request to the server, I even can not find the problem.

Ethan Feldman

JW Player Support Agent  
0 rated :

Because they are running in different modes (flash vs html5 mode).

t...

User  
0 rated :

No. Chrome, Internet Explorer and Safari all running in html5 mode. Only FireFox running in flash.
If running in flash, you can not change playbackRate, but I can change playbackRate in Chrome, Internet Explorer and Safari. This shows all running in html5.

I think this problem caused by JW PLayer (and only occurs in Chrome). Because when the user seeks in the video, JW Player won't send any request nor event to Chrome nor the server.

When the user seek, JW Player may be try to find the part to play, but can not handling the video properly. So, the video stops or looping pause and play. Isn't it?

Ethan Feldman

JW Player Support Agent  
0 rated :

If you look at any of our examples in Chrome in html5 mode, you will see that it seeks fine.

http://support.jwplayer.com/customer/portal/articles/1406723-mp4-video-embed

This question has received the maximum number of answers.