mozilla / popcorn-js

The HTML5 Media Framework. (Unmaintained. See https://github.com/menismu/popcorn-js for activity)
MIT License
2.14k stars 631 forks source link

Preloader #225

Closed HiggsOfChaos closed 12 years ago

HiggsOfChaos commented 12 years ago

Hi,

Another newbie post.

How do I show a vid is loading? In other words how do I show a loading animation while the video is loading.

rwaldron commented 12 years ago

Here is a basic example to get you started: http://jsfiddle.net/rwaldron/rQesE/

HiggsOfChaos commented 12 years ago

Hi Rick,

Thanks.

I tried to implement the code but i figured the local video files I was using did not have the latency to let me see the loading animation.

This made me try the Youtube plugin.

Alas, I cant get it to work.

I even tried a totally striped down page to see what i was doing wrong

Just this JS

// JavaScript Document

// ensure the web page (DOM) has loaded document.addEventListener("DOMContentLoaded", function () {

       // Create a popcorn instance by calling the Youtube player plugin
     var example = Popcorn.youtube(
       '#video',
       'http://www.youtube.com/watch?v=CxvgCLgwdNk' );

  }, false);

And this HTML

<!DOCTYPE html>

Untitled

No Luck.

Its good i found this out now because I planned to move the video up to Youtube when i was done testing.

What do I do?

rwaldron commented 12 years ago

Can someone with experience using the YouTube api chime in? On Oct 3, 2012 5:51 PM, "xkape" notifications@github.com wrote:

Hi Rick,

Thanks.

I tried to implement the code but i figured the local video files I was using did not have the latency to let me see the loading animation.

This made me try the Youtube plugin.

Alas, I cant get it to work.

I even tried a totally striped down page to see what i was doing wrong

Just this JS

// JavaScript Document

// ensure the web page (DOM) has loaded document.addEventListener("DOMContentLoaded", function () {

   // Create a popcorn instance by calling the Youtube player plugin
 var example = Popcorn.youtube(
   '#video',
   'http://www.youtube.com/watch?v=CxvgCLgwdNk' );

}, false);

And this HTML

<!DOCTYPE html>

Untitled

No Luck.

Its good i found this out now because I planned to move the video up to Youtube when i was done testing.

What do I do?

— Reply to this email directly or view it on GitHubhttps://github.com/mozilla/popcorn-js/issues/225#issuecomment-9123685.