Example 1: Using the Default Endcard

Get the Flash Player to see this player.

This sample shows the player loaded with a video duration of 11-seconds and a factor of 50%, allowing for ~5-second time-limit. It uses the default, built-in endcard. No 'endcard' flashVars is used.

Here's the code:

<div id="container">
    <a href="http://www.macromedia.com/go/getflashplayer">Get the Flash Player</a> to see this player.
    <script type="text/javascript">
        var s1 = new SWFObject("player.swf","ply","400","300","9","#000000");
        s1.addParam("allowfullscreen","true");
        s1.addParam("allowscriptaccess","always");
        s1.addVariable("file","video.flv");
        s1.addVariable("duration","11");
        s1.addVariable("plugins","timelimiter");
        s1.addVariable("timelimiter.factor","50");
        s1.addVariable("bufferlength","5");
        s1.write("container");
    </script>
</div> <!-- end container -->


Example 2: Alternate Text for the Default EndCard

Get the Flash Player to see this player.

This sample shows the player loaded with the same duration of 11-seconds and factor of 50%, allowing for ~5-second time-limit. It uses alternate text for the default endCard. This time, the 'endcardtext' flashVars is used.

Here's the code:

<div id="container2">
    <a href="http://www.macromedia.com/go/getflashplayer">Get the Flash Player</a> to see this player.
    <script type="text/javascript">
        var s1 = new SWFObject("player.swf","ply","400","300","9","#000000");
        s1.addParam("allowfullscreen","true");
        s1.addParam("allowscriptaccess","always");
        s1.addVariable("file","video.flv");
        s1.addVariable("duration","11");
        s1.addVariable("plugins","timelimiter");
        s1.addVariable("timelimiter.factor","50");
        s1.addVariable("timelimiter.endcardtext","This EndCard Text was created using flashVars!");

        s1.addVariable("bufferlength","5");
        s1.write("container2");
    </script>
</div> <!-- end container2 -->


Example 3: Using an External Endcard

Get the Flash Player to see this player.

This sample shows the player loaded with the same duration of 11-seconds and factor of 50%, allowing for ~5-second time-limit. It uses an external endcard. This time, the 'endcard' flashVars is used.

Here's the code:

<div id="container3">
    <a href="http://www.macromedia.com/go/getflashplayer">Get the Flash Player</a> to see this player.
    <script type="text/javascript">
        var s1 = new SWFObject("player.swf","ply","400","300","9","#000000");
        s1.addParam("allowfullscreen","true");
        s1.addParam("allowscriptaccess","always");
        s1.addVariable("file","video.flv");
        s1.addVariable("duration","11");
        s1.addVariable("plugins","timelimiter");
        s1.addVariable("timelimiter.factor","50");
        s1.addVariable("timelimiter.endcard","endcard.jpg");

        s1.addVariable("bufferlength","5");
        s1.write("container3");
    </script>
</div> <!-- end container3 -->


Example 4: Using an Erroneous External Endcard

Get the Flash Player to see this player.

This sample once again shows the same video: duration of 11-seconds and a factor of 50%. It uses an external endcard, but I have chosen a filename that does not exist, to show what happens when it encounters an error. The default internal endcard should appear.

Here's the code:

<div id="container4">
    <a href="http://www.macromedia.com/go/getflashplayer">Get the Flash Player</a> to see this player.
    <script type="text/javascript">
        var s1 = new SWFObject("player.swf","ply","400","300","9","#000000");
        s1.addParam("allowfullscreen","true");
        s1.addParam("allowscriptaccess","always");
        s1.addVariable("file","video.flv");
        s1.addVariable("duration","11");
        s1.addVariable("plugins","timelimiter");
        s1.addVariable("timelimiter.factor","50");
        s1.addVariable("timelimiter.endcard","afdsjoifr.jpg");

        s1.addVariable("bufferlength","5");
        s1.write("container4");
    </script>
</div> <!-- end container4 -->


Example 5: Using flashVars for both External endCard and alternate Internal endCard Text

Get the Flash Player to see this player.

This sample once again shows the same video: duration of 11-seconds and a factor of 50%. It tries to use an external endcard, but I have also tried to load new text for the internal endcard, to show what happens when it encounters this particular error. The default internal endcard should appear, but with the new text specified in the flashVars.

Here's the code:

<div id="container5">
    <a href="http://www.macromedia.com/go/getflashplayer">Get the Flash Player</a> to see this player.
    <script type="text/javascript">
        var s1 = new SWFObject("player.swf","ply","400","300","9","#000000");
        s1.addParam("allowfullscreen","true");
        s1.addParam("allowscriptaccess","always");
        s1.addVariable("file","video.flv");
        s1.addVariable("duration","11");
        s1.addVariable("plugins","timelimiter");
        s1.addVariable("timelimiter.factor","50");
        s1.addVariable("timelimiter.endcard","endcard.jpg");

        s1.addVariable("timelimiter.endcardtext","This example tried to call an external endcard, *and* to load this text. Guess who won?");
        s1.addVariable("bufferlength","5");
        s1.write("container5");
    </script>
</div> <!-- end container5 -->