I have some mov, avi, wmv, etc. videos. Does SWF work with these?

Comments

AlexanderPop’s picture

yes it works fine
if you were to put [swf file="video.mp4"] or [swf file="video.mov"] in your node then SWF Tools doesn't know that "mp4" or "mov" is video, so it is given the mixed media action. On the file handling page of SWF Tools you assigned the player you want.
admin/settings/swftools/handling -> "Default player for a list of mixed media:" -> FlowPlayer 3 or JW Media Player 4 show it fine.
In CCK when make filefield - add mp4 mov to file tipe to upload

Stuart Greenfield’s picture

Title: Does SWFtools only work with flv, swf and mp3 files? » Add configuration page to link file extensions with particular actions
Component: SWF Tools » Code

The description from Alexander is correct and describes one way to do it.

The other option is to force the player action using [swf file="video.mp4" action="swftools_flv_display"]. That will push the file to the player assigned for video tasks.

Although the concept of actions is decribed on the input filter documentation page it probably doesn't make it very clear that it can (and sometimes has to) be used in this way.

Thinking out loud, maybe I should add a customisable list to the configuration page to specify how different extensions should be interpreted. A site that allows users to upload content or use the input filter might not realise the need for the action setting.

Changing status and title on this post to reflect that as I think that might be a good option.

AlexanderPop’s picture

to have the configuration page to specify how different extensions should be interpreted - is a great idea! IMHO

Stuart Greenfield’s picture

Version: 6.x-2.5 » 6.x-3.x-dev

I've been working on a configuration page to link extensions with actions - it's mostly done, but not quite ready.

I think I may have over-complicated it though - I've made the page "Profile aware" so you can associate extensions with different actions on different profiles. But now I've done that I'm not sure there are any cases where you'd need it.

For example, you would link m4v with video, but it's always going to be video!

That said, it won't be too hard to take it back. I need to think it over!

To go along with this, and to accommodate private file transfer, we also need configurable file extensions so we can let SWF Tools how to serve content types it doesn't already know about.

Sometimes this project is never ending!

Stuart Greenfield’s picture

Status: Active » Needs review

Committed on DRUPAL-6--3.

Simply go to Administer > Site configuration > SWF Tools > File handling and open the new "Advanced settings" section. You can now explicitly associate extensions with audio, video, image and swf types.

I decided this setting didn't need to be "Profile aware" - an m4v video is always an m4v video, so I simplified the code and made it a global setting.

Remember - if SWF Tools doesn't know what to do with an action it falls back to the mixed media action so in general an appropriate behavior occurs, but this makes it much more explicit.

Q) What should the default list of associations be? For now it's just audio = mp3, video = flv, exactly as it was before.

AlexanderPop’s picture

I think audio = mp3, video = flv is fine

armyofda12mnkeys’s picture

I realized my .flv files get displayed fine. but .mov files get displayed by Mixed Media option. So i set that same as the Video setting, but the audio doesn't play.

I used JW MediaPlayer and Flowplayer3... both have same results with no audio even when adding the action param. Do these players support audio in mentioned files?