Installation Instructions
This is a helper part of the project to help you implement the SL2 Video Player.
- Obtain the VideoPlayer.xap file from the Releases tab above.
- There are 2 versions of the player. If all you want is the smallest payload with basic playback functionality (no markers/closed-captioning), get the VideoPlayerM.xap version
- Put the VideoPlayer.xap file into your web application. If you want to follow standard Silverlight protocol, you'd create a folder at the root of your web site called ClientBin and put it there.
- Implement the Silverlight application in your page(s).
- If you are using HTML, here is a sample piece of markup to demonstrate. Please refer to the Silverlight documentation for complete specification of the Silverlight plugin.
<div id="silverlightControlHost">
<object data="data:application/x-silverlight-2," type="application/x-silverlight-2" width="640" height="480">
<param name="source" value="ClientBin/VideoPlayer.xap"/>
<param name="background" value="white" />
<param name="initParams" value="m=Bear.wmv" />
<param name="minruntimeversion" value="2.0.31005.0" />
<a href="http://go.microsoft.com/fwlink/?LinkId=124807" style="text-decoration: none;">
<img src="http://go.microsoft.com/fwlink/?LinkId=108181" alt="Get Microsoft Silverlight" style="border-style: none"/>
</a>
</object>
</div>
- If you are using ASP.NET and the asp:Silverlight control your implementation would look like this:
<div style="height:100%;">
<asp:Silverlight ID="Xaml1"
runat="server"
Source="~/ClientBin/VideoPlayer.xap"
MinimumVersion="2.0.31005"
Width="640" Height="480" InitParameters="m=Bear.wmv" />
</div>
- Remember these are only sample implementation of the plugin using the application. You should consider adding error event handlers, etc. as specified by the Silverlight SDK documentation.
- In each (HTML and ASP.NET) implementation, the initParams (or InitParameters if using the ASP.NET control). Various types of parameters are supported. The definitions of these parameters are specified in the Initialize Parameters page.
- What if my users's don't have Silverlight installed? - this is a great question. See some tips on creating a 'Silverlight Not Installed' message to your users.