∟Outdated: Playing Flash as "object[@data]" on IE 8
This section provides a tutorial example on how IE 8 renders Flash files specified in the 'data' attribute of an 'object' element.
To see how IE handles the Flash provided in the "data" attribute of
an "object" element, I opened object_swf.html created in the previous section with IE 8,
and got a warning message first,
"To help protect your security, Internet Explorer has restricted
this webpage from running scripts or ActiveX controls that
could access your computer. Click here for options..."
in the information bar.
I clicked the warning message and selected the "Allow Blocked Content..." option.
The "Security Warning" dialog box showed up saying:
"Allowing active content such as script and ActiveX controls
can be useful. However, active content might also harm your computer.
- Are you sure you want to let this file run active content?"
I clicked the "Yes" button.
Flash Player ActiveX got executed and I saw
and saw an animation running in test 2 section only:
What I learned from the result:
Test 1 shows that IE 8 is smart to use the file name extension to determine the content type
and run the Flash Player ActiveX to render the flash file.
But the flash file is rendered in a 0px by 0px display area, because no "width" and "height" provided.
Test 2 shows that IE 8 works correctly with "width" and "height" provided. "type" attribute is optional.
Test 3 shows that IE 8 does not recognizes type="application/x-shockwave-flash" as Flash content type.
This is why a white box is showing on the page.
However, when I uploaded object_swf.html to my Apache Web server and open it remotely,
IE 8 gave me identical result without any warning messages!
So what is the difference between opening object_wsf.html as a local file
and as a remote Web page? Why IE behaves differently?
I have no idea.
Comparing with Firefox 3, IE 8 behaves poorly on playing Flash files provided in "object" elements.
"object" element with "data" attribute and without "type" attribute can make IE 8 play Flash files correctly.