ASP.NET - video displaying

Asked By madhu krishna on 20-Jul-11 01:06 AM
<ASPNetVideo:WindowsMedia ID="WindowsMedia1" runat="server" FullScreen="true" Width="200"
                                                                Height="200" AutoPlay="true"  LoopCount="1">
                                                            </ASPNetVideo:WindowsMedia>

WindowsMedia1.VideoURL = "~/ADMIN/prodvideos/" + videods.Tables[0].Rows[0]["videofiles"].ToString();

i have taken the windows media player to display the video content.However i want to make this to open all formats of the videos and should be compatible with all the main browsers(IE,mozilla,opera,chrome).
what all pluginsor configurations that i need to do for this ? could any one let me know?
Jitendra Faye replied to madhu krishna on 20-Jul-11 01:13 AM

The following works for me in Firefox and Internet Explorer.

<object id="mediaplayer" classid="clsid:22d6f312-b0f6-11d0-94ab-0080c74c7e95" codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#version=5,1,52,701" standby="loading microsoft windows media player components..." type="application/x-oleobject" width="320" height="310">
<param name="filename" value="./test.wmv">
     <param name="animationatstart" value="true">
     <param name="transparentatstart" value="true">
     <param name="autostart" value="true">
     <param name="showcontrols" value="true">
     <param name="ShowStatusBar" value="true">
     <param name="windowlessvideo" value="true">
     <embed src="./test.wmv" autostart="true" showcontrols="true" showstatusbar="1" bgcolor="white" width="320" height="310">
</object>
Anoop S replied to madhu krishna on 20-Jul-11 03:02 AM

I recently worked through this and came up with an ASP.NET C#-based solution that worked for the following browsers (tested on XP): Internet Explorer 7, Firefox 3.0.10, Opera 9.64, Safari 4.0, Google Chrome 2.0 and Flock 2.5.

What it comes down to is writing a bit of server-side C# to generate one object tag syntax for IE and another one for "everyone else".

Here's a link to the full post with ASP.NET/C# source code and a live example:

http://mikeknowles.com/blog/2009/06/16/MultipleBrowserWindowsMediaPlayerObjectTag.aspx

dipa ahuja replied to madhu krishna on 20-Jul-11 04:09 AM
hi..sometime that is depended on the client machine also.

If the client's pc doesn't have for ex a flash player installed, then he/she have to download the flash player for their website

you don't need to have worry about the client's machine because some installation of plug ins client have to installed by them selves.

If this video is running using the flash player then if the client will open your site, he/she will be automatcally be alerted that you are required to installed flash player to view this video.

Hope you get it!