Fixing Plone's publishing of Flash content in Plone 3.1.6 and earlier
Purpose
Per http://www.adobe.com/devnet/flashplayer/articles/fplayer10_security_changes_02.html#head32, Adobe has restricted the ways in which Flash content can be provided. Specifically, Flash Player 10 will ignore all .swf files provided with the 'Content-Disposition: attachment' HTTP response header.
What does this mean?
It means that any .swf files uploaded to a Plone site as a Plone content object will no longer work.
Prerequisities
This works in Plone 2.5, 3.0, and 3.1 up to 3.1.6. This fix will likely be integrated into a future release of ATContentTypes.
Step by step
You'll need to edit a python script to make it work - Products/ATContentTypes/content/file.py.
In the ATFile class, you'll see the following attribute:
inlineMimetypes= ('application/msword',
'application/x-msexcel', # ?
'application/vnd.ms-excel',
'application/vnd.ms-powerpoint',
'application/pdf)
Change it to add the 'application/x-shockwave-flash' content type, as such:
inlineMimetypes= ('application/msword',
'application/x-msexcel', # ?
'application/vnd.ms-excel',
'application/vnd.ms-powerpoint',
'application/pdf',
'application/x-shockwave-flash')
Restart your Plone instance, and it's fixed!
Further information
This issue was originally indicated at http://www.littled.net/new/2008/10/17/plone-and-flash-player-10/. Thanks to David Little for figuring out what was going wrong, and mentioning is in his blog. It would have taken much longer to figure out how to fix this without that information.
