<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
	<channel>
		<title>Playlist start time</title>
		<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time</link>
		<description>LongTail Video forum thread: Playlist start time</description>
		<ttl>60</ttl>
		<language>en-us</language>
		<copyright>some rights reserved (cc)</copyright>
		<pubDate>Sat, 21 Nov 2009 06:13:36 -0500</pubDate>
		<lastBuildDate>Sat, 04 Jul 2009 13:27:50 -0400</lastBuildDate>
		<atom:link href="http://www.longtailvideo.com/jw/rss/?thread=16625" rel="self" type="application/rss+xml" />
		<item>
			<dc:creator>Adam</dc:creator>
			<title><![CDATA[I was "lost" and now I'm found.  Appreciate it!]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg123217</link>
			<description><![CDATA[I was "lost" and now I'm found.  Appreciate it!]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg123217</guid>
			<pubDate>Sat, 04 Jul 2009 13:27:50 -0400</pubDate>
		</item>
		<item>
			<dc:creator>lost</dc:creator>
			<title><![CDATA[You can put any of the [b]File properties[/b] flashvars ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg123152</link>
			<description><![CDATA[You can put any of the [b]File properties[/b] flashvars that you want in the playlist using a meta element for XSPF or the jwplayer namespace for MediaRSS. You can also use your own flashvars for special needs.

XSPF[code]<meta rel='type'>video</meta>[/code]
MediaRSS[code]<jwplayer:type>video</jwplayer:type>[/code]
See: [b]http://developer.longtailvideo.com/trac/wiki/FlashFormats#XMLPlaylists[/b]

File properties: [b]http://developer.longtailvideo.com/trac/wiki/FlashVars#Fileproperties[/b]]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg123152</guid>
			<pubDate>Fri, 03 Jul 2009 13:40:18 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Adam</dc:creator>
			<title><![CDATA[I am a developer new to using the JWPlayer.  So far, so ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg123148</link>
			<description><![CDATA[I am a developer new to using the JWPlayer.  So far, so good.

As an OOP I like reuse.  Therefore, my implementation includes the use of XML playlist.  However, my host is smart to the FLV extension.  I am certain they are blocking binaries with no extension and those with FLV.

I did find that I can play file with extension TXT while setting flashvar 'type' to 'video'.  If only a playlist 'type' entry was supported.

Would support 'type' in the playlist be a worthy feature request?  If so, how do I log such?

Thanks,

Adam

http://adamcox.net
http://vorba.com
]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg123148</guid>
			<pubDate>Fri, 03 Jul 2009 13:04:48 -0400</pubDate>
		</item>
		<item>
			<dc:creator>lost</dc:creator>
			<title><![CDATA[You're welcome.  Enjoy!      [b][i]Good L ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122746</link>
			<description><![CDATA[You're welcome.  Enjoy!
 
 
    [b][i]Good Luck![/i][/b]
]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122746</guid>
			<pubDate>Mon, 29 Jun 2009 17:05:46 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Roy</dc:creator>
			<title><![CDATA[It works perfectly now !!!! Thanks you for all your hel ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122743</link>
			<description><![CDATA[It works perfectly now !!!! Thanks you for all your help !!]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122743</guid>
			<pubDate>Mon, 29 Jun 2009 17:02:40 -0400</pubDate>
		</item>
		<item>
			<dc:creator>lost</dc:creator>
			<title><![CDATA[Damn strings!Replace this whole function.[code]  ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122735</link>
			<description><![CDATA[Damn strings!

Replace this whole function.[code]
      function startTime()
      {
        playlist = player.getPlaylist();

        if(playlist.length > 0)
        {
          var currentTime  = new Date();
          var hoursminutes = 1 * (currentTime.getHours() + '.' + ((currentTime.getMinutes() < 10) ? '0' + currentTime.getMinutes() : currentTime.getMinutes()));
//alert('hoursminutes: ' + hoursminutes);

          for(var j in playlist)
          {
            gid('start').innerHTML = 'ITEM: ' + j + ' START TIME: ' + playlist[j].starttime + ' CURRENT TIME: ' + hoursminutes;
//alert(j + ' : ' + hoursminutes + ' : ' + playlist[j].starttime);

            if((1 * playlist[j].starttime) > hoursminutes)
            {
              player.sendEvent('ITEM', (j - 1));
              gid('start').innerHTML = 'ITEM: ' + (j - 1) + ' START TIME: ' + playlist[j - 1].starttime + '   CURRENT TIME: ' + hoursminutes;
//alert('Track: ' + (j - 1) + ' Start Time: ' + playlist[j - 1].starttime);
              break;
            }
          }
        }
        else
        {
          setTimeout("startTime();", 100);
        }
      };

[/code]
I also took care of the case where minutes have a leading zero.
]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122735</guid>
			<pubDate>Mon, 29 Jun 2009 16:42:56 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Roy</dc:creator>
			<title><![CDATA[Oke i got it working now with hours. But when i do it w ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122725</link>
			<description><![CDATA[Oke i got it working now with hours. But when i do it with minutes it do not work. It always plays the first track. 

Working version with hours :
http://www.videosdelen.nl/flvplayer/index2.html

Not working version with hours and minutes :
http://www.videosdelen.nl/flvplayer/index3.html

http://www.videosdelen.nl/flvplayer/playlist3.xml]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122725</guid>
			<pubDate>Mon, 29 Jun 2009 15:16:04 -0400</pubDate>
		</item>
		<item>
			<dc:creator>lost</dc:creator>
			<title><![CDATA[You need to add a few more tracks to your playlist beca ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122697</link>
			<description><![CDATA[You need to add a few more tracks to your playlist because it will always go backward one track.

In other words, if the local time is 16:30 and the starttime is 17, the player will load the previous track with a starttime of 16 until the local time is 17:01, if there is a starttime greater than 17.

The last track should have a starttime of 24, which will never be played, because it will always go back one track.
]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122697</guid>
			<pubDate>Mon, 29 Jun 2009 12:30:26 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Roy</dc:creator>
			<title><![CDATA[changed it but it gives the same problem...]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122688</link>
			<description><![CDATA[changed it but it gives the same problem...]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122688</guid>
			<pubDate>Mon, 29 Jun 2009 11:46:11 -0400</pubDate>
		</item>
		<item>
			<dc:creator>lost</dc:creator>
			<title><![CDATA[You have a mistake here:[code][b]/Movie[/b] ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122685</link>
			<description><![CDATA[You have a mistake here:[code]
<location>[b]/Movie[/b]http://www.videosdelen.nl/flv/video3.flv</location>

[/code]
]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122685</guid>
			<pubDate>Mon, 29 Jun 2009 11:22:27 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Roy</dc:creator>
			<title><![CDATA[i copied your code exactly but it didn't work for me. Y ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122681</link>
			<description><![CDATA[i copied your code exactly but it didn't work for me. You can see it on this url :

http://www.videosdelen.nl/flvplayer/index2.html

http://www.videosdelen.nl/flvplayer/playlist2.xml]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122681</guid>
			<pubDate>Mon, 29 Jun 2009 11:15:00 -0400</pubDate>
		</item>
		<item>
			<dc:creator>lost</dc:creator>
			<title><![CDATA[Here's the exact code that I posted above, functioning  ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122661</link>
			<description><![CDATA[Here's the exact code that I posted above, functioning correctly: [b]http://willswonders.myip.org:8074/Roy.html[/b]

The playlist is available at: [b]http://willswonders.myip.org:8074/playlist_domenico.xml[/b] if it would be helpful to you.

See brokenString's post of Apr. 21, 2009 for the correct time format if you are using hours and minutes.
]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122661</guid>
			<pubDate>Mon, 29 Jun 2009 10:29:49 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Roy</dc:creator>
			<title><![CDATA[It did not work for me :( when i set the time in the pl ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122652</link>
			<description><![CDATA[It did not work for me :( when i set the time in the playlist on 15:05 and 15:11 and i visit the site onn 15:11 i get two messages that you can see in the screenshot i uploaded. And than the player start with the first movie file !

http://img1.foto-hosting.nl/33427playlist1.jpg

http://img1.foto-hosting.nl/229035playlist2.jpg]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122652</guid>
			<pubDate>Mon, 29 Jun 2009 09:16:09 -0400</pubDate>
		</item>
		<item>
			<dc:creator>lost</dc:creator>
			<title><![CDATA[The time in the playlist is the time on the client. ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122573</link>
			<description><![CDATA[The time in the playlist is the time on the client.

This should work better — tested & working.
[code]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

<html lang="en">

  <head>

    <title>Simple Play On Schedule - JWMP v4.4.x - swfobject v2.1</title>

    <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/swfobject/2.1/swfobject.js"></script>

    <script type="text/javascript">
      var flashvars =
      {
        'file':                                  'playlist_domenico.xml',
        'playlist':                              'right',
        'playlistsize':                          '400',
        'repeat':                                'none',
        'shuffle':                               'false',
        'stretching':                            'none',
        'skin':                                  'bright',
        'frontcolor':                            '86C29D',  // text & icons                  (green)
        'backcolor':                             '003367',  // playlist background           (blue)
        'lightcolor':                            'C286BA',  // selected text/track highlight (red)
        'screencolor':                           '000000',  // screen background             (white)
        'id':                                    'playerID1',
        'autostart':                             'true'
      };

      var params =
      {
        'allowfullscreen':                       'true',
        'allowscriptaccess':                     'always',
        'bgcolor':                               '#000000'
      };

      var attributes =
      {
        'name':                                  'playerID1',
        'id':                                    'playerID1'
      };
      
      swfobject.embedSWF('player-4.5.223.swf', 'player1', '900', '327', '9.0.124', false, flashvars, params, attributes);
    </script>

    <script type="text/javascript">
      var player    =  null;
      var playlist  =  null;


      function playerReady(obj)
      {
        player = gid(obj.id);
        startTime();
      };


      function startTime()
      {
        playlist = player.getPlaylist();

        if(playlist.length > 0)
        {
          var currentTime  = new Date();
          var hoursminutes = 1 * (currentTime.getHours() + '.' + currentTime.getMinutes());

          for(var j in playlist)
          {
alert(hoursminutes + ' : ' + playlist[j].starttime);
            if(playlist[j].starttime > hoursminutes)
            {
alert('Track: ' + j + ' Start Time: ' + playlist[j].starttime);
              player.sendEvent('ITEM', (j - 1));
              gid('start').innerHTML = 'START TIME: ' + playlist[j - 1].starttime + '   CURRENT TIME: ' + hoursminutes + '   ITEM: ' + (j -1);
              break;
            }
          }
        }
        else
        {
          setTimeout("startTime();", 100);
        }
      };


      function gid(name)
      {
        return document.getElementById(name);
      };
    </script>

  </head>

  <body>

    <div id="playercontainer1" class="playercontainer"><a id="player1" class="player" href="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash">Get the Adobe Flash Player to see this video.</a></div>
    <div id="start" style="font-family:arial;">START TIME:     CURRENT TIME:     ITEM:</div>

  </body>

</html>

[/code]
[b][i]Change the playlist filename and the player version.[/i][/b]

Comment out the alerts when they get annoying.
]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122573</guid>
			<pubDate>Sun, 28 Jun 2009 22:10:13 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Roy</dc:creator>
			<title><![CDATA[I have tryed the supported script but i did not work. I ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122560</link>
			<description><![CDATA[I have tryed the supported script but i did not work. I did everything i had read here but nothing works. The player always started with the first clip. Can someone please look at it ? 
http://www.videosdelen.nl/flvplayer/index2.html

xml :

http://www.videosdelen.nl/flvplayer/playlist2.html

I also had another question. is the time that you fill in the xml file the server time or the time of windows ?]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg122560</guid>
			<pubDate>Sun, 28 Jun 2009 17:21:05 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Cesar</dc:creator>
			<title><![CDATA[thanks again for your contributions.  Longtail has not  ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg119899</link>
			<description><![CDATA[thanks again for your contributions.  Longtail has not replied to me, they might not be interested in small projects under $5000 (hint*hint*contactus!).

any developers willing to implement this please contact me @ satamusic@gmail.com

alivepubs.com]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg119899</guid>
			<pubDate>Tue, 02 Jun 2009 12:27:09 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Mattias</dc:creator>
			<title><![CDATA[Thanks to all of those who participated in this thread. ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg119139</link>
			<description><![CDATA[Thanks to all of those who participated in this thread. I've been pondering this problem for a while and you've all helped immensely. [b]Gratzie[/b]!]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg119139</guid>
			<pubDate>Sat, 23 May 2009 00:09:36 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Sebastian</dc:creator>
			<title><![CDATA[Hey all,some nice suggestions above, thank you! ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg118050</link>
			<description><![CDATA[Hey all,

some nice suggestions above, thank you!

Anyway... by now I'm not very happy with this type of schedule. Using Javascript to read the current position in the playlist is always a bit risky. Thinking about different plattforms (e.g. mobile devices) or gaming devices, they will often block JS (whops!) or something else.

Currently I try to build a playlist with the known structure, but all the videos should be stored in a live-instance of my Adobe Flash Media Server. So we get one RTMP-Link for the Player. I like the approach of a server-side playlist and not one on the client side.

Does anyone has some experience with this?]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg118050</guid>
			<pubDate>Tue, 12 May 2009 19:33:45 -0400</pubDate>
		</item>
		<item>
			<dc:creator>satamusic@gmail</dc:creator>
			<title><![CDATA[thanks for the above contributions.if any one is in ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116703</link>
			<description><![CDATA[thanks for the above contributions.

if any one is interested in extending the above code examples (for pay) to a solution that lets you schedule what gets played per week, per day, per hour, right down to the minute;

i am aware that Longtail mentions they don't take any flash work for less than $2000, so freelancers please reply.  i'm sure this work is nowhere near $2000.

i'm sending this to the longttailvideo contact form too.

Cesar satamusic@gmail.com]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116703</guid>
			<pubDate>Tue, 28 Apr 2009 15:36:37 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Martin Campbell</dc:creator>
			<title><![CDATA[Re; The SEEK calculation. I think that the "offset" as  ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116506</link>
			<description><![CDATA[Re; The SEEK calculation. I think that the "offset" as worked out above is in 1/100's of minutes, so you need to multiply it by 100 and then by 60 to convert it into seconds. ]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116506</guid>
			<pubDate>Sun, 26 Apr 2009 14:33:17 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Martin Campbell</dc:creator>
			<title><![CDATA[I agree that using a delay is not a good idea, so I hav ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116486</link>
			<description><![CDATA[I agree that using a delay is not a good idea, so I have replaced the delay with a listener in an addlisteners function that is called by the playerReady function. 

player.addModelListener("STATE", "startTime");

Then removed it before instructing the player.

player.removeModelListener("STATE", "startTime");
player.sendEvent('STOP');
player.sendEvent('ITEM', (j-1)); 

This works, once for the page, and once correctly again if the page is re-loaded. Then the playlist will simply carry on in sequential order. 

I'm not sure if this is the most efficient way of solving this problem (ie using ModelListener), so any better solutions would be interesting. Thanks for the "seek" enhancement, I'll test this too, particularly if the time elapsed is greater than the length of the item. 

Martin   ]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116486</guid>
			<pubDate>Sun, 26 Apr 2009 06:33:48 -0400</pubDate>
		</item>
		<item>
			<dc:creator>brokenString</dc:creator>
			<title><![CDATA[The script starts the track at 00:00.You could enha ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116402</link>
			<description><![CDATA[The script starts the track at 00:00.

You could enhance the script to SEEK to a position within the selected track, that was based upon the amount of time that had elapsed since your start time.

After the index, calculate the offset and send a seek.
[code]
player.sendEvent('ITEM', (j - 1));
var offset = hoursminutes - playlist[j - 1].starttime;
player.sendEvent('SEEK', offset);

[/code]
]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116402</guid>
			<pubDate>Fri, 24 Apr 2009 12:54:32 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Hi</dc:creator>
			<title><![CDATA[And I forgot to say, that I'm using mix between rtmp, a ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116400</link>
			<description><![CDATA[And I forgot to say, that I'm using mix between rtmp, and fake php stream, or as you call it, scheduled play-list with files, and the files in the sever not rtmp....]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116400</guid>
			<pubDate>Fri, 24 Apr 2009 12:41:28 -0400</pubDate>
		</item>
		<item>
			<dc:creator>Hi</dc:creator>
			<title><![CDATA[Sorry,So as I understood, this script will play the ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116397</link>
			<description><![CDATA[Sorry,

So as I understood, this script will play the track from where it should be started?

for example, I have many tracks, and one of them scheduled to play at 13:00 am, lets call it track007, and the track duration is 5:24 minutes. Now, a visitor opened the website at 13:02:00 am , then track007 will start from minute 2:01 ?

is this possible?
]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116397</guid>
			<pubDate>Fri, 24 Apr 2009 12:37:43 -0400</pubDate>
		</item>
		<item>
			<dc:creator>brokenString</dc:creator>
			<title><![CDATA[Using a delay is very problematic. For most users, the  ..]]></title>
			<link>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116385</link>
			<description><![CDATA[Using a delay is very problematic. For most users, the delay is far too long, yet there is always the case where the delay isn't long enough and the application fails.

The method that we're using waits until it receives a valid playlist (usually between 50-100ms), then performs the indexing. This makes it both quick and robust.
]]></description>
			<guid>http://www.longtailvideo.com/support/forum/Setup-Problems/16625/Playlist-start-time#msg116385</guid>
			<pubDate>Fri, 24 Apr 2009 10:38:10 -0400</pubDate>
		</item>
	</channel>
</rss>