
Video is slow buffering on first access - how to get around?
Hello!
I am helping a friend with their website. It is a very simple one with mostly html and links. We have a flv video we want to embedded and I loaded up the JWplayer on the server.
The player plays fine except on the first access because the streaming isn't quick enough. I am guessing it is mostly the server which is a cheap one and is known to be slow (GoDaddy - ugh). On second time great because, well obviously, the video is already loaded and in the cache.
I am trying to figure out how to work around this. Here is my player code below. I also found some code on here and I tried to apply it for pre-loading and buffereing but I don't think it is working because even when I clear my cache or go a hard clear (to skip the cache) - it can be fast or slow - it seems random. It might be missing something or in the wrong spot on my page.
Javascript is not my expertise - and although I have done some along with VB and asp.net in the past on a few websites - it has been long time. So I am pretty rusty about where to put code, what order, etc.
bc.. <div id='player'>Loading the player..please stand by!</div>
<script type='text/javascript' src='/jwplayer/jwplayer.js'></script>
<script type='text/javascript'>
jwplayer('player').setup({
'flashplayer': '/jwplayer/player.swf',
'width': '600',
'height': '400',
'file': 'http://www.oursite.com/files/video.flv',
'image': 'http://www.oursite.com/files/videoframe.jpg',
'plugins':
{ 'sharing-3':
{ 'link': 'http://www.oursite.com/index.htm',
'code': '%3Cembed%20src%3D%22http%3A%2F%2Fexample.com%2Fplayers%2F12345.swf%22%20width%3D%22480%22%20height%3D%22270%22%20allowfullscreen%3D%22true%22%20%2F%3E'
}
}
});
</script>
What sort of code can do (simple as possible) that will prevent this first slow load for users once they press the play arrow? Is it the server that is to blame mostly (I am a server newb - only know some basics) or can I do some workaround to get a more smoother first play? If I could successfully reload the video so it is ready in the player that would be great. But there is not much on the page (like I said -real simple) so the page loads rather quickly except the video.
Ps. that is not the real site name it is a fake one.
Thanks!
queen