Embed FLV in MediaWiki – The Other Holy Grail

Embed FLV in MediaWiki

Now that the blog/wiki mashup era has begun, it’s time to extend those technologies. Ever since I began using wikis, and MediaWiki specifically, I thought “that’s cool, an instantly editable page”. However, it wasn’t a media-rich technology. Inline images were about the extent of the multimedia offerings. Then, back in January, I discovered the YouTube Extension which offered a way to place YouTube (or Google) videos inline in a wiki page. That, of course, got me thinking that it must be possible to do it with any Flash Video file (FLVs). Poking around at the MediaWiki third-party extension page turned up this extension for a DreamHost Flash Player. Dreamhost has created a player that will allow its customers to embed streaming audio/video onto their web pages. This information pushed me closer to the Holy Grail. Thinking about how the existing pieces worked led me to see that it was doable in MediaWiki. The key to all this is some javascript that detects Flash and embeds Flash objects. Bobby van der Sluis has come up with a script called Unobtrusive Flash Objects (UFO) that makes the embedding possible. The last piece of this puzzle is a Flash player, and there aren’t many better than Jeroen Wijering’s Flash Video Player.

So the simple ingredients are:

Flashplayer.swf – This is what plays the embedded FLV
ufo.js – This is the javascript that assists in the embed process
dhflashplayer.php – The MediaWiki extension (gets place in the “extension” directory)

The LocalSettings.php then gets modified to point to the dhflashplayer extension and that’s it. Now you use some special code to embed your video in MediaWiki. Something like this:

dhflashplayer

You can see the demo and view some more detailed instructions on the new UMW New Media Wiki.

For even more detail, I’ve created a screencast entitled How to Embed FLV Video in MediaWiki.

13 Comments

  1. Wow, the magic just keeps on coming. Who’s better than you? I guess, two of you!

  2. Awesome blog with great advice. I recently added the dhflashplayer to Appropedia (see Hexayurt for an example). Do you know an easy way to use the dhflashplayer extension to embed YouTube videos in MediaWiki, or should I use the YouTube extension for that?

    Thank you.

  3. Lonny,

    A well written extension for adding YouTube videos can be found at Jim Wilson’s site:
    http://jimbojw.com/wiki/index.php?title=YouTubeTag_Extension

  4. Hi Andy,

    My YouTubeTag Extension has been deprecated in favor of the EmbedVideo Extension[1]. EmbedVideo uses a nicer syntax which allows interpretation of template parameters (whereas YouTubeTag, VideoFlash and even Dreamhost’s dhflashplayer cannot).

    EmbedVideo can display videos from YouTube, Google Video, Revver, sevenload, Dailymotion, and Funny or Die out-of-the-box, and can support arbitrary other services by specifying them in the LocalSettings.php configuration file. Details on how to do this are on the EmbedVideo homepage.

    1. http://jimbojw.com/wiki/index.php?title=EmbedVideo_Extension

  5. Hmmm…I followed the instructions as carefully as I could. There are some new updates to the files since you’ve posted this, but other than that everything was the same.

    And still I can’t get it to play nice. When I travel to my testing media page I get the “Download the player” link instead of my video.

    Any thought?

  6. No thoughts right now Doug. I haven’t looked at it in a while, so I haven’t tried the updates. I’ll update if I come up with anything.

  7. I know this may sound silly, but, could I get copies of the file that you used for your video?

    At least if I have the original files you used and it still doesn’t work then I know it’s something else I did and not the files.

    Also, in your video you talk about a series of projects you did on working with wikis. Are there any links to those discussions? (I like my wiki but I’m sure it could be prettier)

    Thanks again.

  8. You can download the video that I use at:

    http://www.umwdtlt.org/media/video/flv/web20.flv

    The rest of the files are freely downloadable.

  9. Sadly I’m having the same experience as Doug.
    Would you mind telling us which version of Mediawiki you were using at the time of install… along with any other version numbers involved.

    Doug, are you using fckeditor by any chance? I’d like to know what we have in common. I’m at Mediawiki 1.11

  10. Sadly I’m having the same experience as Doug.
    Would you mind telling us which version of Mediawiki you were using at the time of install… along with any other version numbers involved.

    Doug, are you using fckeditor by any chance? I’d like to know what we have in common. I’m at Mediawiki 1.11

  11. I’m using version 1.6.8 of MediaWiki

  12. I am experiencing a similar problem as Leonardo and Dough.

    When embeding a single player on one of the wiki page, it plays that video. However, when adding a second player, the previous one shows the Download Flash Player link.

    Updating my Flash Plug-in did not update this problem.

    MediaWiki 1.10

    If there is a limitation on how many players can be placed on 1 wiki page, how can this limitation be changed and how multiple players be added?

    Thank you.

  13. I currently have it working in a MediaWiki 1.10 install. I just did the upgrade and it didn’t break it. As far as I can see there is no limit on how many you put on a page. Let me remind people here that there may be better info on the authors’ websites. I also came across a new extension for video on MediaWiki called Kaltura. You can get the MediaWiki extension or a WordPress plugin at http://corp.kaltura.com/download .

1 Pingback

  1. theroades.com

Comments are closed.

© 2017 And He Blogs

Theme by Anders NorenUp ↑