Wowza Community

playlist using php mysql

So I am trying to generate a playlist based on entries in a mysql database. I’m not sure how to structure the code for the playlist. The examples flowplayer gives doesn’t look like it is geared for wowza. Here is my code:

<html><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
    <!-- flowplayer javascript component -->
    <script type="text/javascript" src="flowplayer-3.2.9.min.js"></script>
    </head>
<body>
    <script type="text/javascript">
	$f("container3", "flowplayer-3.2.10.swf", 
		{
			clip: {
				provider: 'rtmp'
			},
			playlist [
<?php
while($row = mysql_fetch_array($result))
  {
 $title = $row['title'];
	echo "			'mp4:" . $title . "',\n";
}
mysql_close($con);
?> 
			],
			plugins: {
				rtmp: {
				url: 'flowplayer.rtmp-3.2.9.swf',
				netConnectionUrl: 'rtmp://[my-ip]:1935/vod'
				}
            		controls: {
                	playlist: true
			loop: true
            			}
			}
		}
	);
</script>
       
</body>
</html>

Anyone know what I am missing? I get no errors, but the clips never play.

You might be able to use the player’s visibile playlist feature and make it not visible and make it play and loop, which is essentially what I think you are trying to achive.

Otherwise, you will have to get into the Actionscript, I don’t think you can do this through the html container. You are trying to do this:

netstream.play("video1",0,-1, true);
netstream.play("video2",0,-1, false);
netstream.play("video3",0,-1, false);

Note that the first item has to have the reset flag (4th arg) set to true, and false in every following item to form a playlist.

Richard