Playing Flash as "object[@data]" - Example

This section provides a tutorial example on how to play Flash files, .swf files, using 'data' attribute in an 'object' element.

Flash data files, .swf files, can also be displayed in Web pages as <object> elements. To show you how to include Flash data files using the "data" attribute in an "object" element, I wrote the following tutorial example, object_swf.html:

<html><body>
<!-- object_swf.html
 - Copyright (c) 2014, HerongYang.com, All Rights Reserved.
-->

<p>1. Flash with "object[@data]":</p>
<table border="1" cellpadding="0" cellspacing="0">
<tr><td>
<object data="yahoo.swf">
Halloween on Yahoo!
</object>
</td></tr>
</table>

<p>2. Flash with "object[@data and @width and @height]":</p>
<table border="1" cellpadding="0" cellspacing="0">
<tr><td>
<object data="yahoo.swf" width="217" height="85">
Halloween on Yahoo!
</object>
</td></tr>
</table>

<p>3. Flash with "object[@data and @type and @width and @height]":</p>
<table border="1" cellpadding="0" cellspacing="0">
<tr><td>
<object data="yahoo.swf" type="application/x-shockwave-flash"
   width="100" height="100">
Halloween on Yahoo!
</object>
</td></tr>
</table>

</body></html>

In this example, I created 3 tests with 3 <object> elements to test 4 attributes: "data", "type", "width" and "height":

If you want to see my test results, read next sections.

Last update: 2014.

Table of Contents

 About This Book

 Introduction of Adobe Flash

 Adobe Flash Player Plugin for Firefox

 Adobe Flash Player Plugin for Chrome

 Adobe Flash Player Plugin for Safari

 Adobe Flash Player ActiveX for IE

Using "object" Elements for Flash Files

 What Is "object" Element?

 Displaying Images as "object" Elements - Example

 Displaying Images as "object" Elements on Firefox 26

 Displaying Images as "object" Elements on IE 10

Playing Flash as "object[@data]" - Example

 Playing Flash as "object[@data]" on Firefox 26

 Playing Flash as "object[@data]" on IE 10

 Playing Flash as "object[@classid]"

 Playing Flash as "object[@classid]" - Example

 Playing Flash as "object[@classid]" on Firefox 26

 Playing Flash as "object[@classid]" on IE 10

 Playing Flash with Nested "object" Elements

 Playing Flash with a Single "object" Element

 Using "embed" Elements for Flash Files

 "mp3player" - MP3 Music Player

 SWFObject - Hidding "object" behind JavaScript

 Flash Player Projector

 SWFTools - SWF File Manipulation Tools

 SWFC Script to Generate Flash SWF Files

 ActionScript Embedded in SWFC Script

 AS3Compile - ActionScript 3 Compiler

 Adobe Flex SDK 4

 SWF File Struture and Tags

 SWF File Processing Rules

 SWF Files for Video and Audio Streams

 Outdated Tutorials

 References

 PDF Printing Version