Display video on asp.net form - webforms

My application is allowing users to upload videos(avi and wmv) and then those videos should be displayed on users home page. Uploaded file is saved on server and path to the file is saved in database.
What is the best way to display those videos on page?
I'm using ASP.NET forms.
Thanks

ASP.net does not have any video or media controls natively. Some people have tried the MediaPlayer control, however this is an ActiveX control so browser compatibility is a major issue. Depending on what formats you are accepting a variety of solutions from simple to complicated exist and can be broken down to two categories:
HTML5 Video
You can use the basic HTML5 Video, depending on what formats you have (avi, mp4, oog, etc.) you will need to have multiple source files for compatiblity across all browsers.
A list of compatible formats for each browser can be found here:W3 Schools HTML5 Video Tutorial
You can add runat="server" and access the properties directly. I've found adding multiple sources requires setting inner text and adding a new src tag.
Third Party Tools
These can be great for cross-browser compatibility and include FlowPlayer, Telerik's Media Player Control, jVideo and others. Solutions like FlowPlayer can fallback to Flash in the event a browser is not compatible with the format and still play. Some are free, some are not. You can wrap a control without server-side methods (FlowPlayer) into a user control depending on what you need.

Related

How to save screen shot of a web page?

I want to save screen shot of a web page.But I don't know how.Just like the app delish.In delish ,when i add a bookmark ,the app capture the website and save it such as p5.delish.I guess the screenshot comes from the file of the ".delish".How can i produce this file? or some one has some samples like this app? Thanke you very much!
This might help you: http://allseeing-i.com/ASIWebThumbnail/
ASIWebThumbnail is:
A command line tool for generating thumbnails from web pages
An API to use an embedded version of the tool in your Cocoa applications
ASIWebThumbnail uses the WebKit framework built-in Mac OS X to render web pages. As such, it should support any content that WebKit supports, including HTML/XML + CSS, SVG, content rendered by Javascript (Canvas, AJAX, DOM etc), Java, as well as Flash and other plugins.

flash player or silver light?

i want to create a help video and put theme on my web site.
i did some search i internet to find whats the best way to do it.
use flash player or use Microsoft silver light technology to do this?
what s the best open source video player for my case?
my site is on mvc3 razor on .net4.0
and my video are in .wvm format off course i can convert theme
to any other format
please guide me which one of them is better and have advantage rather than other?
thanks all
My suggestion would be to use neither and use HTML 5 and the Video element.
Flash and Silverlight are becoming deprecated technologies for Web UI's now.
You could use third party libraries such as modernizr to detect the browser capabilities and respond accordingly.
This page contains cross-browser polyfills, search the page for Video

Is there a standard Control for creating an in-app video player?

Im making a videoplayer in a wp7 app. Im using mediaelement to show the video, and sets its source from a url. Functionality i wanted are play/stop-buttons, forwarding/rewinding, a progressindicator (for the progress of the video itself) and show a progressbar when it buffers. I have accomplished all above, using some customized grids, buttons and so on.
I did get some trouble though, which i dont want to bother you with here (its a mess) and which is why im asking the following:
Is there a standard (or downloadable) control for wp7 that does all these things for me and that works perfectly. Ive searched "everywhere" but couldnt find anything. It surprises me that this isnt an easy to use, built in control that is easy to customize, since standard videoplayers are something id guess alot of apps could take advantage of.
Anyone?
Here is a tutorial on how to create a Windows Phone 7 View Model Style Video Player.

How to handle downloads in mobile site

How does one handle image downloads in a mobi site - using jquery mobile and asp.net mvc 3 and have a requirement to allow a user to download wallpapers to their mobile.
Can you trigger a download or is best to simply simple the image to them and let them handle the saving?
Any input appreciated.
Typically, you can force the download of content on standard browsers by setting headers
"Content-Disposition", "attachment; filename=\"LicenseAgreement.pdf\""
on the return. This SO shows how to return a PDF file but theoretically, you could do the same with an image.
How can I present a file for download from an MVC controller?
However, it is questionable if every browser that is supported by jquery mobile would even respect that and give any kind of a save prompt or just open the image in a new window. Give it a shot but test it on iOS, Android, WinPhone 7.5+, and (gagging) Blackberry 6+ and see what happens because they're probably going to all behave a little differently.
Were it me, I'd simply link directly to the image either on the current page or with a target="_blank" and let them save it however they usually save images.

What is the best option for creating an in-browser UI-editor?

I want to create an simple UI-editor that can be used within the browser. It basically should have a UI-control palette and a canvas to layout and modify the controls. The resulting user-created UI model should be stored in some kind of backend and comply to an (abstract) UI description language (e.g. XForms). The UI-model should be downloadable as file (e.g. XForms document). A visual in-browser XForms-designer is probably a good example of what I want to achieve. The UI-editor should be usable cross browser.
Please keep in mind that i mentioned XForms only as an example. I don't want to rely on the browsers capabilities wrt. my target model. The target model (e.g. XForms) should only be used as storage format. The cross browser rendering of the desgin-time UIs in the editor should be ensured by the toolkit/framework.
Possible canditates are probably:
GWT
Adobe Flex 3
Eclipse RAP
The UI-editor will not be used in production. My focus lies on a rapid development of the editor.
The extjs JavaScript library is good for implementing GUIs in JavaScript. It can also be used with Adobe AIR or Google Gears for creating offline applications, and works well with different browsers.
Here is an example of a GUI editor for extjs: http://tof2k.com/ext/formbuilder/

Resources