Order Now AdSolution Sign Up | Login » Bits on the Run Sign Up | Login »

Forums

/

d-playlist open new item in same player?

7 replies [Last post]

Not sure if this double posted but is it possible to use Flashvar: dplaylists.dtarget and have the item open in the same player?

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">

<html>

  <head>

    <title>Simple D-Playlists - JWMP v4.5.x - swfobject v2.2</title>

    <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/swfobject/2.2/swfobject.js"></script>

    <script type="text/javascript">
      var flashvars =
      {
        'file':                                  '/Movies/video1.flv',
        'image':                                 'image01.jpg',
        'controlbar':                            'bottom',
        'skin':                                  'bekle',
        'plugins':                               'http://www.domain.com/dplaylists/dplaylists-1',
        'dplaylists.dxmlpaths':                  'http://www.domain.com/dplaylists/choice.xml,http://www.domain.com/dplaylists/latest.xml', //link to the XML containing related clips
        'dplaylists.dskin':                      'http://www.domain.com/dplaylists/DPlaylistsSample.swf',
        'dplaylists.dposition':                  'top',    // center, bottom, top
        'dplaylists.dtarget':                    '_self',  // where to open the related videos when clicked on    
        'id':                                    'playerId',
        'autostart':                             'false'
      };

      var params =
      {
        'allowfullscreen':                       'true',
        'allowscriptaccess':                     'always',
        'bgcolor':                               '#FFFFFF'
      };

      var attributes =
      {
        'id':                                    'playerId',
        'name':                                  'playerId'
      };

      swfobject.embedSWF('player-4.5.227.swf', 'player1', '470', '320', '9.0.124', false, flashvars, params, attributes);
    </script>

    <script type="text/javascript">
      var player = null;

      function playerReady(obj)
      {
        player = gid(obj.id);
      };

      function loadNplay(file)
      {
        player.sendEvent('LOAD', {file:file});
        player.sendEvent('PLAY', 'true');
      };

      function gid(name)
      {
        return document.getElementById(name);
      };
    </script>

  </head>

  <body>

    <div id="playercontainer1" class="playercontainer1"><a id="player1" class="player1" href="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash">Get the Adobe Flash Player to see this video.</a></div>

  </body>

</html>

choice.xml

<?xml version="1.0" encoding="utf-8"?>
<videolist>
  <title>Choice</title>
  <key>choice</key>
  <video id="001">
    <title>Video 2</title>
    <thumb>/dplaylists/thumbs/video2.jpg</thumb>
    <url>javascript:loadNplay('/Movies/video2.flv')</url>
    <duration>1:31</duration>
  </video>
  <video id="002">
    <title>Video 3</title>
    <thumb>/dplaylists/thumbs/video3.jpg</thumb>
    <url>javascript:loadNplay('/Movies/video3.flv')</url>
    <duration>1:31</duration>
  </video>
  <video id="003">
    <title>Video 4</title>
    <thumb>/dplaylists/thumbs/video4.jpg</thumb>
    <url>javascript:loadNplay('/Movies/video4.flv')</url>
    <duration>1:31</duration>
  </video>
</videolist>

@lost,

You just made my day. Thanks!

Hi,

Is there any way of removing the editors choice button?

Thanks

Currently not supported

This doesn't seem to work anymore in the JW Player 5.

Works for me… could you post a link to a page demonstrating the error?

could anyone upload (speedyshare or sth) an example [as archive seems the best] of working player with this playlist?
it doesn't work on my page, even default example of d-playlist :(
very thanks !