To follow this code walkthrough, you will need on_demand_player.zip, the sample file download that accompanies this article. Here's what you should do with the contents of the ZIP archive:
It's easy to change your default applications folder. Open conf/fms.ini in a text editor and change the variable VHOST.APPSDIR.
Flash Media Server 2 has two applications that control the logic, FileObj and MyCollection (see Figure 1). When OnDemandPlayer.swf is instantiated, it accesses FileObj, which returns the content into a DataGrid. When the user clicks an object in the DataGrid, it calls the video based in MyCollection.
Figure 1. Connection between OnDemandPlayer.swf and Flash Media Server 2