Video Sharing Sites like Youtube or Google video provide simple HTML code for embedding their video clips in your web pages. But sometimes we want to add raw Flash Video files like SWF animations or FLV [streaming or progressive] which are frequently used by News or media websites.

Now to embed flash video files, you can either download the flv or swf flash video to your hard drive, convert it to avi, wmv or mov format and then upload it to your Youtube account. Then you can use the Youtube supplied HTML code to embed that video in your webpage or blog. The video will play wrapped inside the Youtube or Google Video player skin.

The above approach works but is clearly not the best way to do things. What if the original video is updated - then you will have to revisit the whole encoding-decoding cycle again. Secondly, there will be considerable loss in video quality when it is converted from one format to another and Youtube is definitely not the best place to see high resolution video clips. They will degrade it to 320x240 size clip.

So here's a very easy way for embedding flash videos in your website without loosing any quality. Also you won't have to download the video to your own server - you can embed the flash video player in your site and it will stream the video [or play directly] from the source website [you might want to obtain permission from the content host since you will be consuming his bandwidth]

To do this, just copy-paste the following HTML snippet in your blog template and replace the height, width and streamName parameters with real values [you can find the video size (dimensions) and URL of the flash video by looking at the HTML source code of the webpage where the video is originally embedded]



Incase you would like the video to start only when the site visitor hits the play button, replace autoPlay=true with autoPlay=false. Once the video track finishes playing, the cue marker would return to the original position. You can disable this by setting autorewind=false.

Here's a real world example - this flash video is hosted on an external news website in flv format but has been embedded in this site using just the above HTML code. See the video player skin is non-branded and looks more sleek and professional.

References: Flash Video, Flash Dev Center, Community MX, On2 Flash Streaming

Related: Embed Streaming Web Video in Web Pages, Do Interesting Things with Youtube Video Clips