Get Multiple Videos to Play on a Single Player
When you get a player that includes playlist function, you can play multiple videos on one web page. With the player generated by Moyea PlayerBox, you can make player recognize different playlist file by changing the HTML code. The Flash file will load XML file with FLV videos.
1. Get your web FLV player.
You can download sample players with playlist from the Skins page on player-box.com .
You may also generate your own player with Moyea PlayerBox. If you have not installed the program yet, click here to download the free trial version. Please add playlist component to follow this guide.
2. Get your playlist file ready.
The playlist file is an XML file with .mmpl as extension. The playlist file shall contain FLV video. Thus, the first step is to get your FLV video URL. You can use the URL of your domain or existing FLV HTTP URL, FLV RTMP URL.
If you are familiar with coding, just open the XML with text editor like notepad, and modify the value of videoURL= option. The thumbnail= option is for the item image on playlist.
If you are still a beginner for web page, you can use the bundled Moyea FLV Player with Moyea PlayerBox to generate playlist file. You can run the bundled Moyea FLV Player from the Start menu if you did not change settings when installing Moyea PlayerBox. Choose Start > All Programs > Moyea > PlayerBox > Moyea FLV Player. Choose File > Open Files to load videos. Choose View > Display Playlist and a section will show up with the video names you added. Right click on the playlist section and save playlist. For more information about editing playlist, please refer to How to edit your playlist.
3. Pass HTML parameter to Flash SWF.
There are 3 ways to pass HTML code to Flash SWF:
• Add query string at the end of the SWF address
• Use FlashVars to transfer parameter
• Control with JavaScript (JS)
The JavaScript include other coding outside HTML page, thus we do not discuss about this in this article. To enable Flash movie to play on most client machines, it is recommended to include < Object > tag and < Embed > tag in HTML page. It is easy to modify Flash variables in HTML.
Here is the sample code with Object and Embed tags for the SWF file named testing.
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="480" height="400">
<param name="movie" value="testing.swf">
<param name="quality" value="high">
<param name="allowScriptAccess" value="sameDomain" />
<param name="allowFullScreen" value="True" />
<embed src="testing.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="480" height="400" allowScriptAccess="sameDomain" allowFullScreen="True">
</embed>
</object >
If you upload the SWF file and the playlist file to the same folder, you can use the following code to pass HTML parameter code to SWF. Supposed that the playlist file is named moyea, the file name with extension for the playlist file is then moyea.mmpl.
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="480" height="400">
<param name="movie" value="testing.swf?playList=moyea.mmpl">
<param name="quality" value="high">
<param name="allowScriptAccess" value="sameDomain" >
<param name="allowFullScreen" value="True">
<embed src="testing.swf?playList=moyea.mmpl" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="480" height="400" allowScriptAccess="sameDomain" allowFullScreen="True">
</embed>
</object>
You can also use the direct URL of the playlist file. If you upload to a folder named "file", here is the sample:
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="480" height="400">
<param name="movie" value="testing.swf?playList=http://www.yourdomoain.com/file/moyea.mmpl">
<param name="quality" value="high">
<param name="allowScriptAccess" value="sameDomain" />
<param name="allowFullScreen" value="True" />
<embed src="testing.swf?playList=http://www.yourdomoain.com/file/moyea.mmpl" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="480" height="400" allowScriptAccess="sameDomain" allowFullScreen="True">
</embed>
</object>
This is to add a new FlashVars parameter like < param name="FlashVars" value="playList="> below the Movie parameter.
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="480" height="400">
<param name="movie" value="testing.swf ">
<param name="FlashVars" value="playList=moyea.mmpl">
<param name="quality" value="high">
<param name="allowScriptAccess" value="sameDomain" />
<param name="allowFullScreen" value="True" />
<embed src="testing.swf" FlashVars="playList=moyea.mmpl" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="480" height="400" allowScriptAccess="sameDomain" allowFullScreen="True">
</embed>
</object>
To use direct playlist file URL, just replace the file name to URL.
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="480" height="400">
<param name="movie" value="testing.swf">
<param name="FlashVars" value="playList=http://www.yourdomoain.com/file/moyea.mmpl">
<param name="quality" value="high">
<param name="allowScriptAccess" value="sameDomain" />
<param name="allowFullScreen" value="True" />
<embed src="testing.swf" FlashVars="playList=http://www.yourdomoain.com/file/moyea.mmpl" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="480" height="400" allowScriptAccess="sameDomain" allowFullScreen="True">
</embed>
</object>
The URL used above is based on the condition that the playlist file is uploaded to the folder named "file".
Learn More About Moyea PlayerBox
Free Trial
1. Get your web FLV player.
You can download sample players with playlist from the Skins page on player-box.com .
You may also generate your own player with Moyea PlayerBox. If you have not installed the program yet, click here to download the free trial version. Please add playlist component to follow this guide.
2. Get your playlist file ready.
The playlist file is an XML file with .mmpl as extension. The playlist file shall contain FLV video. Thus, the first step is to get your FLV video URL. You can use the URL of your domain or existing FLV HTTP URL, FLV RTMP URL.
If you are familiar with coding, just open the XML with text editor like notepad, and modify the value of videoURL= option. The thumbnail= option is for the item image on playlist.
If you are still a beginner for web page, you can use the bundled Moyea FLV Player with Moyea PlayerBox to generate playlist file. You can run the bundled Moyea FLV Player from the Start menu if you did not change settings when installing Moyea PlayerBox. Choose Start > All Programs > Moyea > PlayerBox > Moyea FLV Player. Choose File > Open Files to load videos. Choose View > Display Playlist and a section will show up with the video names you added. Right click on the playlist section and save playlist. For more information about editing playlist, please refer to How to edit your playlist.
3. Pass HTML parameter to Flash SWF.
There are 3 ways to pass HTML code to Flash SWF:
• Add query string at the end of the SWF address
• Use FlashVars to transfer parameter
• Control with JavaScript (JS)
The JavaScript include other coding outside HTML page, thus we do not discuss about this in this article. To enable Flash movie to play on most client machines, it is recommended to include < Object > tag and < Embed > tag in HTML page. It is easy to modify Flash variables in HTML.
Here is the sample code with Object and Embed tags for the SWF file named testing.
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="480" height="400">
<param name="movie" value="testing.swf">
<param name="quality" value="high">
<param name="allowScriptAccess" value="sameDomain" />
<param name="allowFullScreen" value="True" />
<embed src="testing.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="480" height="400" allowScriptAccess="sameDomain" allowFullScreen="True">
</embed>
</object >
If you upload the SWF file and the playlist file to the same folder, you can use the following code to pass HTML parameter code to SWF. Supposed that the playlist file is named moyea, the file name with extension for the playlist file is then moyea.mmpl.
Add query string at the end of the SWF address
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="480" height="400">
<param name="movie" value="testing.swf?playList=moyea.mmpl">
<param name="quality" value="high">
<param name="allowScriptAccess" value="sameDomain" >
<param name="allowFullScreen" value="True">
<embed src="testing.swf?playList=moyea.mmpl" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="480" height="400" allowScriptAccess="sameDomain" allowFullScreen="True">
</embed>
</object>
You can also use the direct URL of the playlist file. If you upload to a folder named "file", here is the sample:
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="480" height="400">
<param name="movie" value="testing.swf?playList=http://www.yourdomoain.com/file/moyea.mmpl">
<param name="quality" value="high">
<param name="allowScriptAccess" value="sameDomain" />
<param name="allowFullScreen" value="True" />
<embed src="testing.swf?playList=http://www.yourdomoain.com/file/moyea.mmpl" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="480" height="400" allowScriptAccess="sameDomain" allowFullScreen="True">
</embed>
</object>
Use FlashVars to transfer parameter
This is to add a new FlashVars parameter like < param name="FlashVars" value="playList="> below the Movie parameter.
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="480" height="400">
<param name="movie" value="testing.swf ">
<param name="FlashVars" value="playList=moyea.mmpl">
<param name="quality" value="high">
<param name="allowScriptAccess" value="sameDomain" />
<param name="allowFullScreen" value="True" />
<embed src="testing.swf" FlashVars="playList=moyea.mmpl" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="480" height="400" allowScriptAccess="sameDomain" allowFullScreen="True">
</embed>
</object>
To use direct playlist file URL, just replace the file name to URL.
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="480" height="400">
<param name="movie" value="testing.swf">
<param name="FlashVars" value="playList=http://www.yourdomoain.com/file/moyea.mmpl">
<param name="quality" value="high">
<param name="allowScriptAccess" value="sameDomain" />
<param name="allowFullScreen" value="True" />
<embed src="testing.swf" FlashVars="playList=http://www.yourdomoain.com/file/moyea.mmpl" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="480" height="400" allowScriptAccess="sameDomain" allowFullScreen="True">
</embed>
</object>
The URL used above is based on the condition that the playlist file is uploaded to the folder named "file".
Learn More About Moyea PlayerBox
Free Trial



