Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
Hi,
I am presently working on mobile site.That mobile site will play the videos and audio files on web site using .net.My task is play the files with out flash player.
 
If You know any solution for my question,Please share the answer for me.
 

Thanks in Advance.
Posted 8-Jul-13 1:01am
Comments
dholakiyaankit at 8-Jul-13 6:07am
   
you should use dll for that one without flash player there is vimeo also try to find some inbuilt dlls on gooooooooooooogle.
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 3

  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 4

Try this....Smile | :)
 
1)VideoPlay.aspx
 
<html xmlns="http://www.w3.org/1999/xhtml">
<head  runat="server">
    <title></title>
</head>
<body>
    <form id="form1"  runat="server">
    <div>
    <table style="width: 400px;" border="0" cellpadding="2" cellspacing="3">
        <tr>
            <td style="width: 150px;" valign="top">
            </td>
            <td style="width: 200px;" valign="top" align="left">
                <asp:label id="lblMsg" cssclass="tdMessage" text="" runat="server" xmlns:asp="#unknown"></asp:label>
            </td>
        </tr>
        <tr>
            <td class="tdText" valign="top" align="left">
                <nobr> Select a file</nobr>
            </td>
            <td style="text-align: left;" valign="top">
                <asp:fileupload id="fUpload" runat="server" width="300px" xmlns:asp="#unknown"></asp:fileupload>
            </td>
        </tr>
        <tr>
            <td valign="top" align="left">
                <asp:button id="btnUpload" runat="server" text="Upload" onclick="btnUpload_Click" xmlns:asp="#unknown">
                </asp:button>
            </td>
            <td valign="top" align="left">
                <object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0">
                    width="200" height="100">
                    <param name="movie" value="<% =swfFileName%>">
                    <param name="quality" value="high">
                    <embed src="<%=swfFileName%>" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer">
                        type="application/x-shockwave-flash" width="200" height="100">
                </embed></param></param></object>
            </td>
        </tr>
    </table>
    </div>
    </form>
</body>
</html>
 
2)VideoPlay.aspx.cs
 
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.IO;
 
namespace VideoDemo
{
    public partial class VDemo : System.Web.UI.Page
    {
        public string swfFileName;
        protected void Page_Load(object sender, EventArgs e)
        {
 
        }
        protected void btnUpload_Click(object sender, EventArgs e)
     {
        if (fUpload.FileContent.Length >0 && IsVaildFile())
        {
            string Path = GetUplaodImagePhysicalPath();
            DirectoryInfo dirUploadImage = new DirectoryInfo(Path);
            if (dirUploadImage.Exists == false)
            {
                dirUploadImage.Create();
            }
            string fileUrl = Path + fUpload.PostedFile.FileName;
            fUpload.PostedFile.SaveAs(fileUrl);
            swfFileName = "images/" + fUpload.PostedFile.FileName;
        }
    }
    private bool IsVaildFile()
    {
        string swfExt = System.IO.Path.GetExtension(fUpload.PostedFile.FileName);
        switch (swfExt)
        {
            case ".swf":
                return true;
            default:
            {
                    lblMsg.Text = "Please select only swf file.";
                    return false;
            }
        }
    }
 
 
    
    string GetUplaodImagePhysicalPath()
    {
        return System.Web.HttpContext.Current.Request.PhysicalApplicationPath + "images\\";
    }
  
} 
    
}
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Use Video tag if you using html5
ex:
<html>
<body>
 
<video width="300" height="250" controls="">
  <source src="mymovie.mp4" type="video/mp4">
  <source src="mymovie.ogg" type="video/ogg">
  Your browser does not support the video tag.
</source></source></video>
 
</body>
</html>
  Permalink  
v2
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 6

Hi...
am used for audio and video playing with in literal using asp.net.
how to upload and play video into database..
Thank u.
  Permalink  
v4

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 280
1 Sergey Alexandrovich Kryukov 279
2 CPallini 205
3 Maciej Los 162
4 Afzaal Ahmad Zeeshan 160
0 OriginalGriff 5,635
1 DamithSL 4,496
2 Maciej Los 3,942
3 Kornfeld Eliyahu Peter 3,480
4 Sergey Alexandrovich Kryukov 3,180


Advertise | Privacy | Mobile
Web01 | 2.8.141216.1 | Last Updated 17 Jul 2013
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100