-
Notifications
You must be signed in to change notification settings - Fork 3
An extremely lightweight, jquery-based alternative to the massive swfobject library.
Qard/jquery-flash
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
Use jquery-flash like this; <script type="text/javascript"> $(document).ready(function(){ $('#flash').flash(); }); </script> This particular example converts this; <a id="flash" href="http://www.youtube.com/v/Br8zEBwv81Y">Javascript disabled! Click here for video.</a> to a youtube video object. jquery-flash will automagically inherit classes, ids, dimensions and href from the original container unless you specify them in the constructor like this; <script type="text/javascript"> $(document).ready(function(){ $('#flash').flash({ 'src':'http://www.nerdculture.org/wp-content/uploads/audioplayer/mediaplayer.swf', 'width':'480', 'height':'300', 'allowfullscreen':'true', 'allowscriptaccess':'always', 'version': '9.0.24', 'flashvars': { 'file':'http://www.nerdculture.org/wp-content/uploads/music/playlist.xml', 'displayheight':'0', 'backcolor':'0xFFFFFF', 'frontcolor':'0x666666', 'lightcolor':'0xFF6600', 'thumbsinplaylist':'true', 'width':'480', 'height':'300' } }); }); </script> Express Install is supported by adding an 'express' line to the constructor json object with the url of the express install swf. If the user's flash version is less than the number specified by 'version' express install will be place in place of the one provided in 'src'. If no flash is installed the original element will be left completely untouched, so it's easy to put in a "no flash" image and replace it with jquery-flash. jquery-flash adds 3 extra functions now; isie(); // returns boolean hasflash(); // returns boolean flashversion(); // returns array ["10","0","45"] Everything else functions exactly the same way, it's just a little more flexible now. :)
About
An extremely lightweight, jquery-based alternative to the massive swfobject library.
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published