Flash Satay

From Wikipedia, the free encyclopedia

Flash Satay is a method of coding for display of Flash video content in (X)HTML while adhering to the w3c standards. It was developed in 2002 by Drew McLellan and announced in his article "Flash Satay: Embedding Flash While Supporting Standards", a copy of which may be found online here.

McLellan states his goals for the project to be:

  • Produce a simpler standard code fragment for invoking a Flash movie;
  • Use only valid XHTML;
  • Produce a single code fragment that works in both Internet Explorer and Netscape (and similar browsers); and
  • Retain the full functionality of the previously common but non-conforming approaches.

In his article, McLellan details his approach and how he devised it. The approach involved a dummy flash movie that loads another movie, the name of which is passed to the dummy. The XHTML code uses the Object element with an application type rather than a classid.

McLellan called his technique 'Flash Satay' as a counter-response to the traditional methods, which due to technical limitations include the movie twice in each page ('twice cooked').

The Flash Satay method has become a widely used coding technique for embedding Flash into valid, standards-compliant (X)HTML documents. Several variations on and refinements of the method have been used by other (X)HTML coders.

Unfortunately this method also has drawbacks. The loadMovie function automatically makes the loaded movie's background transparent. This can be a problem for movies that depend on their background color to display properly. Currently there is no known fix for this. Additionally, defects in the JAWS screen reader can result in the content of a movie not being read when Flash Satay is used.

[edit] Example code

Here's an example of a code to insert Flash to a (X)HTML page, generated by Dreamweaver:

<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="500" height="400"><param name="movie" value="flashfile.swf" /><param name="quality" value="high" /><embed src="flashfile.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="500" height="400" /></embed></object>

Now, the Flash Satay version:

<object type="application/x-shockwave-flash" data="flashfile.swf" width="500" height="400"><param name="movie" value="flashfile.swf" /></object>

To make the Flash file transparent, this line should be added between the object tags:

<param name="wmode" value="transparent" />

[edit] External links