[BUGFIX] Improve usability of new Media element flexform
authorSteffen Ritter <info@rs-websystems.de>
Sat, 31 Mar 2012 16:39:18 +0000 (18:39 +0200)
committerSteffen Ritter <info@rs-websystems.de>
Wed, 11 Apr 2012 11:21:53 +0000 (13:21 +0200)
With HTML5 video many new options are added to the media element
flexform. This results in a very hard to read form.

Restructure the fields into tabs and use display conditions
to hide unneeded fields depending on the selected media type.

Change-Id: I1a25a17506541a3461bcd83d320a395bad3f8195
Fixes: #35433
Releases: 6.0,4.7
Reviewed-on: http://review.typo3.org/10109
Reviewed-by: Dominik Mathern
Tested-by: Dominik Mathern
Reviewed-by: Markus Klein
Tested-by: Markus Klein
Reviewed-by: Steffen Ritter
Tested-by: Steffen Ritter
Reviewed-on: http://review.typo3.org/10223

typo3/sysext/cms/flexform_media.xml
typo3/sysext/cms/locallang_ttc.xlf
typo3/sysext/cms/tslib/content/class.tslib_content_media.php

index fb3c825..050fe58 100644 (file)
@@ -4,7 +4,7 @@
                <langDisable>1</langDisable>
        </meta>
        <sheets>
-               <sDEF>
+               <sGeneral>
                        <ROOT>
                                <TCEforms>
                                        <sheetTitle>LLL:EXT:cms/locallang_ttc.xml:media.options</sheetTitle>
@@ -13,6 +13,7 @@
                                <el>
                                        <mmType>
                                                <TCEforms>
+                                                       <onChange>reload</onChange>
                                                        <label>LLL:EXT:cms/locallang_ttc.xml:media.type</label>
                                                        <config>
                                                                <type>select</type>
                                                        </config>
                                                </TCEforms>
                                        </mmType>
-                                       <mmSources>
-                                               <title>LLL:EXT:cms/locallang_ttc.xml:media.sources</title>
+                                       <mmWidth>
+                                               <TCEforms>
+                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.width</label>
+                                                       <config>
+                                                               <type>input</type>
+                                                               <size>8</size>
+                                                               <max>5</max>
+                                                               <eval>trim,num</eval>
+                                                       </config>
+                                               </TCEforms>
+                                       </mmWidth>
+                                       <mmHeight>
+                                               <TCEforms>
+                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.height</label>
+                                                       <config>
+                                                               <type>input</type>
+                                                               <size>8</size>
+                                                               <max>5</max>
+                                                               <eval>trim,num</eval>
+                                                       </config>
+                                               </TCEforms>
+                                       </mmHeight>
+                                       <mmRenderType>
+                                               <TCEforms>
+                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.renderType</label>
+                                                       <config>
+                                                               <type>select</type>
+                                                               <items>
+                                                                       <numIndex index="0">
+                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.renderType.preferHtml5OverFlash</numIndex>
+                                                                               <numIndex index="1">auto</numIndex>
+                                                                       </numIndex>
+                                                                       <numIndex index="1">
+                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.renderType.preferFlashOverHtml5</numIndex>
+                                                                               <numIndex index="1">preferFlashOverHtml5</numIndex>
+                                                                       </numIndex>
+                                                                       <numIndex index="2">
+                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.renderType.qt</numIndex>
+                                                                               <numIndex index="1">qt</numIndex>
+                                                                       </numIndex>
+                                                                       <numIndex index="3">
+                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.renderType.embed</numIndex>
+                                                                               <numIndex index="1">embed</numIndex>
+                                                                       </numIndex>
+                                                               </items>
+                                                               <itemsProcFunc>tx_cms_mediaItems->customMediaRenderTypes</itemsProcFunc>
+                                                       </config>
+                                               </TCEforms>
+                                       </mmRenderType>
+                                       <mmMediaOptions>
+                                               <title>LLL:EXT:cms/locallang_ttc.xml:media.additionalOptions</title>
                                                <type>array</type>
                                                <section>1</section>
                                                <el>
-                                                       <mmSourcesContainer>
+                                                       <mmMediaOptionsContainer>
                                                                <type>array</type>
-                                                               <title>LLL:EXT:cms/locallang_ttc.xml:media.media.url</title>
+                                                               <title>LLL:EXT:cms/locallang_ttc.xml:media.params</title>
                                                                <el>
-                                                                       <mmSource>
+                                                                       <mmParamName>
                                                                                <TCEforms>
-                                                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.url</label>
+                                                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.params.option</label>
+                                                                                       <config>
+                                                                                               <type>select</type>
+                                                                                               <items>
+                                                                                                       <numIndex index="0">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.autoPlay</numIndex>
+                                                                                                               <numIndex index="1">autoPlay</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="1">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.loop</numIndex>
+                                                                                                               <numIndex index="1">loop</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="2">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.quality</numIndex>
+                                                                                                               <numIndex index="1">quality</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="3">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.preview</numIndex>
+                                                                                                               <numIndex index="1">preview</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="4">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.allowScriptAccess</numIndex>
+                                                                                                               <numIndex index="1">allowScriptAccess</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="5">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.allowFullScreen</numIndex>
+                                                                                                               <numIndex index="1">allowFullScreen</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="6">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.preload</numIndex>
+                                                                                                               <numIndex index="1">preload</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="7">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.controlsBelow</numIndex>
+                                                                                                               <numIndex index="1">controlsBelow</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="8">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.controlsAtStart</numIndex>
+                                                                                                               <numIndex index="1">controlsAtStart</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="9">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.controlsHiding</numIndex>
+                                                                                                               <numIndex index="1">controlsHiding</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="10">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.defaultVolume</numIndex>
+                                                                                                               <numIndex index="1">defaultVolume</numIndex>
+                                                                                                       </numIndex>
+                                                                                               </items>
+                                                                                               <itemsProcFunc>tx_cms_mediaItems->customMediaParams</itemsProcFunc>
+                                                                                       </config>
+                                                                               </TCEforms>
+                                                                       </mmParamName>
+                                                                       <mmParamSet>
+                                                                               <TCEforms>
+                                                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.params.setTo</label>
+                                                                                       <config>
+                                                                                               <type>select</type>
+                                                                                               <items>
+                                                                                                       <numIndex index="0">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.on</numIndex>
+                                                                                                               <numIndex index="1">1</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="1">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.off</numIndex>
+                                                                                                               <numIndex index="1">0</numIndex>
+                                                                                                       </numIndex>
+                                                                                                       <numIndex index="2">
+                                                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.valueEntry</numIndex>
+                                                                                                               <numIndex index="1">2</numIndex>
+                                                                                                       </numIndex>
+                                                                                               </items>
+                                                                                       </config>
+                                                                               </TCEforms>
+                                                                       </mmParamSet>
+                                                                       <mmParamValue>
+                                                                               <TCEforms>
+                                                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.params.value</label>
                                                                                        <config>
                                                                                                <type>input</type>
-                                                                                               <size>60</size>
-                                                                                               <eval>trim,required</eval>
+                                                                                               <size>16</size>
                                                                                                <default></default>
-                                                                                               <wizards type="array">
-                                                                                                       <_PADDING>2</_PADDING>
-                                                                                                       <link type="array">
-                                                                                                               <type>popup</type>
-                                                                                                               <title>LLL:EXT:cms/locallang_ttc.xml:media.browseUrlTitle</title>
-                                                                                                               <icon>link_popup.gif</icon>
-                                                                                                               <script>browse_links.php?mode=wizard&amp;act=file|url</script>
-                                                                                                               <params type="array">
-                                                                                                                       <blindLinkOptions>page,folder,mail,spec</blindLinkOptions>
-                                                                                                                       <allowedExtensions>asf,avi,class,dcr,flv,mov,mpg,mp4,m4a,m4v,ogg,ogv,swf,webm</allowedExtensions>
-                                                                                                               </params>
-                                                                                                               <JSopenParams>height=300,width=500,status=0,menubar=0,scrollbars=1</JSopenParams>
-                                                                                                       </link>
-                                                                                               </wizards>
                                                                                        </config>
                                                                                </TCEforms>
-                                                                       </mmSource>
+                                                                       </mmParamValue>
                                                                </el>
-                                                       </mmSourcesContainer>
+                                                       </mmMediaOptionsContainer>
+                                                       <mmMediaCustomParameterContainer>
+                                                               <type>array</type>
+                                                               <title>LLL:EXT:cms/locallang_ttc.xml:media.params.customEntry</title>
+                                                               <el>
+                                                                       <mmParamCustomEntry>
+                                                                               <TCEforms>
+                                                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.params.customEntryLabel</label>
+                                                                                       <config>
+                                                                                               <type>text</type>
+                                                                                               <rows>6</rows>
+                                                                                               <cols>60</cols>
+                                                                                       </config>
+                                                                               </TCEforms>
+                                                                       </mmParamCustomEntry>
+                                                               </el>
+                                                       </mmMediaCustomParameterContainer>
                                                </el>
-                                       </mmSources>
+                                       </mmMediaOptions>
+                               </el>
+                       </ROOT>
+               </sGeneral>
+               <sVideo>
+                       <ROOT>
+                               <TCEforms>
+                                       <sheetTitle>LLL:EXT:cms/locallang_ttc.xml:media.tabVideo</sheetTitle>
+                                       <displayCond>FIELD:sGeneral.mmType:=:video</displayCond>
+                               </TCEforms>
+                               <type>array</type>
+                               <el>
                                        <mmFile>
                                                <TCEforms>
                                                        <label>LLL:EXT:cms/locallang_ttc.xml:media.fallbackUrl</label>
                                                        </config>
                                                </TCEforms>
                                        </mmFile>
+                                       <mmSources>
+                                               <title>LLL:EXT:cms/locallang_ttc.xml:media.sources</title>
+                                               <type>array</type>
+                                               <section>1</section>
+                                               <el>
+                                                       <mmSourcesContainer>
+                                                               <type>array</type>
+                                                               <title>LLL:EXT:cms/locallang_ttc.xml:media.media.url</title>
+                                                               <el>
+                                                                       <mmSource>
+                                                                               <TCEforms>
+                                                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.url</label>
+                                                                                       <displayCond>FIELD:mmType:=:video</displayCond>
+                                                                                       <config>
+                                                                                               <type>input</type>
+                                                                                               <size>60</size>
+                                                                                               <eval>trim,required</eval>
+                                                                                               <default></default>
+                                                                                               <wizards type="array">
+                                                                                                       <_PADDING>2</_PADDING>
+                                                                                                       <link type="array">
+                                                                                                               <type>popup</type>
+                                                                                                               <title>LLL:EXT:cms/locallang_ttc.xml:media.browseUrlTitle</title>
+                                                                                                               <icon>link_popup.gif</icon>
+                                                                                                               <script>browse_links.php?mode=wizard&amp;act=file|url</script>
+                                                                                                               <params type="array">
+                                                                                                                       <blindLinkOptions>page,folder,mail,spec</blindLinkOptions>
+                                                                                                                       <allowedExtensions>asf,avi,class,dcr,flv,mov,mpg,mp4,m4a,m4v,ogg,ogv,swf,webm</allowedExtensions>
+                                                                                                               </params>
+                                                                                                               <JSopenParams>height=300,width=500,status=0,menubar=0,scrollbars=1</JSopenParams>
+                                                                                                       </link>
+                                                                                               </wizards>
+                                                                                       </config>
+                                                                               </TCEforms>
+                                                                       </mmSource>
+                                                               </el>
+                                                       </mmSourcesContainer>
+                                               </el>
+                                       </mmSources>
                                        <mmCaption>
                                                <TCEforms>
                                                        <label>LLL:EXT:cms/locallang_ttc.xml:media.captionUrl</label>
                                                        </config>
                                                </TCEforms>
                                        </mmCaption>
+
+                               </el>
+                       </ROOT>
+               </sVideo>
+               <sAudio>
+                       <ROOT>
+                               <TCEforms>
+                                       <sheetTitle>LLL:EXT:cms/locallang_ttc.xml:media.tabAudio</sheetTitle>
+                                       <displayCond>FIELD:sGeneral.mmType:=:audio</displayCond>
+                               </TCEforms>
+                               <type>array</type>
+                               <el>
                                        <mmAudioSources>
                                                <title>LLL:EXT:cms/locallang_ttc.xml:media.audioSources</title>
                                                <type>array</type>
                                                        </config>
                                                </TCEforms>
                                        </mmAudioFallback>
-                                       <mmWidth>
-                                               <TCEforms>
-                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.width</label>
-                                                       <config>
-                                                               <type>input</type>
-                                                               <size>8</size>
-                                                               <max>5</max>
-                                                               <eval>trim</eval>
-                                                       </config>
-                                               </TCEforms>
-                                       </mmWidth>
-                                       <mmHeight>
-                                               <TCEforms>
-                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.height</label>
-                                                       <config>
-                                                               <type>input</type>
-                                                               <size>8</size>
-                                                               <max>5</max>
-                                                               <eval>trim</eval>
-                                                       </config>
-                                               </TCEforms>
-                                       </mmHeight>
-                                       <mmRenderType>
-                                               <TCEforms>
-                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.renderType</label>
-                                                       <config>
-                                                               <type>select</type>
-                                                               <items>
-                                                                       <numIndex index="0">
-                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.renderType.preferHtml5OverFlash</numIndex>
-                                                                               <numIndex index="1">auto</numIndex>
-                                                                       </numIndex>
-                                                                       <numIndex index="1">
-                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.renderType.preferFlashOverHtml5</numIndex>
-                                                                               <numIndex index="1">preferFlashOverHtml5</numIndex>
-                                                                       </numIndex>
-                                                                       <numIndex index="2">
-                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.renderType.qt</numIndex>
-                                                                               <numIndex index="1">qt</numIndex>
-                                                                       </numIndex>
-                                                                       <numIndex index="3">
-                                                                               <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.renderType.embed</numIndex>
-                                                                               <numIndex index="1">embed</numIndex>
-                                                                       </numIndex>
-                                                               </items>
-                                                               <itemsProcFunc>tx_cms_mediaItems->customMediaRenderTypes</itemsProcFunc>
-                                                       </config>
-                                               </TCEforms>
-                                       </mmRenderType>
-                                       <mmMediaOptions>
-                                               <title>LLL:EXT:cms/locallang_ttc.xml:media.additionalOptions</title>
-                                               <type>array</type>
-                                               <section>1</section>
-                                               <el>
-                                                       <mmMediaOptionsContainer>
-                                                       <type>array</type>
-                                                       <title>LLL:EXT:cms/locallang_ttc.xml:media.params</title>
-                                                       <el>
-                                                               <mmParamName>
-                                                                       <TCEforms>
-                                                                               <label>LLL:EXT:cms/locallang_ttc.xml:media.params.option</label>
-                                                                               <config>
-                                                                                       <type>select</type>
-                                                                                       <items>
-                                                                                               <numIndex index="0">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.autoPlay</numIndex>
-                                                                                                       <numIndex index="1">autoPlay</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="1">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.loop</numIndex>
-                                                                                                       <numIndex index="1">loop</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="2">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.quality</numIndex>
-                                                                                                       <numIndex index="1">quality</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="3">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.preview</numIndex>
-                                                                                                       <numIndex index="1">preview</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="4">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.allowScriptAccess</numIndex>
-                                                                                                       <numIndex index="1">allowScriptAccess</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="5">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.allowFullScreen</numIndex>
-                                                                                                       <numIndex index="1">allowFullScreen</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="6">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.preload</numIndex>
-                                                                                                       <numIndex index="1">preload</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="7">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.controlsBelow</numIndex>
-                                                                                                       <numIndex index="1">controlsBelow</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="8">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.controlsAtStart</numIndex>
-                                                                                                       <numIndex index="1">controlsAtStart</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="9">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.controlsHiding</numIndex>
-                                                                                                       <numIndex index="1">controlsHiding</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="10">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.defaultVolume</numIndex>
-                                                                                                       <numIndex index="1">defaultVolume</numIndex>
-                                                                                               </numIndex>
-                                                                                       </items>
-                                                                                       <itemsProcFunc>tx_cms_mediaItems->customMediaParams</itemsProcFunc>
-                                                                               </config>
-                                                                       </TCEforms>
-                                                               </mmParamName>
-                                                               <mmParamSet>
-                                                                       <TCEforms>
-                                                                               <label>LLL:EXT:cms/locallang_ttc.xml:media.params.setTo</label>
-                                                                               <config>
-                                                                                       <type>select</type>
-                                                                                       <items>
-                                                                                               <numIndex index="0">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.on</numIndex>
-                                                                                                       <numIndex index="1">1</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="1">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.off</numIndex>
-                                                                                                       <numIndex index="1">0</numIndex>
-                                                                                               </numIndex>
-                                                                                               <numIndex index="2">
-                                                                                                       <numIndex index="0">LLL:EXT:cms/locallang_ttc.xml:media.params.valueEntry</numIndex>
-                                                                                                       <numIndex index="1">2</numIndex>
-                                                                                               </numIndex>
-                                                                                       </items>
-                                                                               </config>
-                                                                       </TCEforms>
-                                                               </mmParamSet>
-                                                               <mmParamValue>
-                                                                       <TCEforms>
-                                                                               <label>LLL:EXT:cms/locallang_ttc.xml:media.params.value</label>
-                                                                               <config>
-                                                                                       <type>input</type>
-                                                                                       <size>16</size>
-                                                                                       <default></default>
-                                                                               </config>
-                                                                       </TCEforms>
-                                                               </mmParamValue>
-                                                       </el>
 
-                                                       </mmMediaOptionsContainer>
-                                                       <mmMediaCustomParameterContainer>
-                                                               <type>array</type>
-                                                               <title>LLL:EXT:cms/locallang_ttc.xml:media.params.customEntry</title>
-                                                               <el>
-                                                                       <mmParamCustomEntry>
-                                                                               <TCEforms>
-                                                                                       <label>LLL:EXT:cms/locallang_ttc.xml:media.params.customEntryLabel</label>
-                                                                                       <config>
-                                                                                               <type>text</type>
-                                                                                               <rows>6</rows>
-                                                                                               <cols>60</cols>
-                                                                                       </config>
-                                                                               </TCEforms>
-                                                                       </mmParamCustomEntry>
-                                                               </el>
-                                                       </mmMediaCustomParameterContainer>
-                                               </el>
-                                       </mmMediaOptions>
                                </el>
                        </ROOT>
-               </sDEF>
+               </sAudio>
        </sheets>
 </T3DataStructure>
index f8f065e..8195bbb 100644 (file)
                        <trans-unit id="media.options" xml:space="preserve">
                                <source>Media Options</source>
                        </trans-unit>
+                       <trans-unit id="media.tabAudio" xml:space="preserve">
+                               <source>Audio Element</source>
+                       </trans-unit>
+                       <trans-unit id="media.tabVideo" xml:space="preserve">
+                               <source>Video Element</source>
+                       </trans-unit>
                        <trans-unit id="media.url" xml:space="preserve">
                                <source>Path or URL</source>
                        </trans-unit>
                                <source>Path or URL to fallback video source (Flash or QuickTime)</source>
                        </trans-unit>
                        <trans-unit id="media.sources" xml:space="preserve">
-                               <source>Video sources</source>
+                               <source>Video sources for HTML5 &lt;video&gt; element</source>
                        </trans-unit>
                        <trans-unit id="media.captionUrl" xml:space="preserve">
                                <source>Path or URL to captions file</source>
                        </trans-unit>
                        <trans-unit id="media.audioSources" xml:space="preserve">
-                               <source>Audio sources</source>
+                               <source>Audio sources for HTML5 &lt;audio&gt; element</source>
                        </trans-unit>
                        <trans-unit id="media.audioFallbackUrl" xml:space="preserve">
                                <source>Path or URL to fallback audio source (Flash or QuickTime)</source>
index a7a194f..6fb49b5 100644 (file)
@@ -48,7 +48,10 @@ class tslib_content_Media extends tslib_content_Abstract {
                        : $conf['flexParams'];
                if (substr($flexParams, 0, 1) === '<') {
                                // It is a content element rather a TS object
-                       $this->cObj->readFlexformIntoConf($flexParams, $conf['parameter.']);
+                       $flexParams = t3lib_div::xml2array($flexParams, 'T3');
+                       foreach($flexParams['data'] as $sheetData) {
+                               $this->cObj->readFlexformIntoConf($sheetData['lDEF'], $conf['parameter.'], TRUE);
+                       }
                }
                        // Type is video or audio
                $mmType = isset($conf['parameter.']['mmType.'])