[jQuery] how to get flash expressinstall working with jquery media and swfobject?
Hi,
I'm using the jquery media plugin (.90) with swfobject (2.1)
My markup has something like this:
<a class="leftmedia {width: 400, height: 350, autoplay: true}
href="somevideo.flv">My video</a>
To load the video, I simply call jQuery('a.leftmedia').media();
If the browser has flash installed, the video loads fine. If it does
not have flash, there's no video displayed and no prompt to install
flash. I'd like to use swfobject's ability to automatically prompt the
user to install flash, but I can't seem to get that working with
jquery media.
I tried modifying jquery.media.js to include the expressInstaller swf
path as follows:
$.fn.media.defaults = {
width: 400,
height: 400,
autoplay: 0, // normalized cross-player setting
bgColor: '#ffffff', // background color
params: { wmode: 'transparent'}, // added to object
element as param elements; added to embed element as attrs
attrs: {}, // added to object and embed elements as
attrs
flvKeyName: 'file', // key used for object src param (thanks
to Andrea Ercolino)
flashvars: {}, // added to flash content as flashvars
param/attr
flashVersion: '7', // required flash version
expressInstaller: 'expressInstall.swf', // src for express
installer
the expressInstaller parameter is null by default in jquery media.
However, adding the expressinstall.swf as I did above doesn't seem to
work.
What do I need to do to my mark-up or javascript to get flash
detection and prompt for installation working when flash isn't
installed?
Thanks!
Tracy