Flash

Functions

Util.flashDetection

Definition

Name
Util.flashDetection
Shorthand
u.flashDetection
Syntax
Boolean = Util.flashDetection( String|Integer version );

Description

Detects if the browser has Flash support.

Parameters

version
String|Integer Optional version requirement
Options
Integer
Specific version to check for
String
Version scope to check for, ie. "<=8" checks for flash version less than or equal to 8.

Returns

Boolean whether the browser has a valid flash plugin

Examples

<script> u.flashDetection(); </script>

Returns true if the browser has a flash plugin of any version.

<script> u.flashDetection(8); </script>

Returns true if the browser has flash plugin, version 8.

<script> u.flashDetection("<=8"); </script>

Returns true if the browser has flash plugin, less or equal to version 8.

<script> u.flashDetection(">8"); </script>

Returns true if the browser has flash plugin, higher than version 8.

Uses

JavaScript
  • isNaN
  • String.match
  • eval
Manipulator

none

Util.flash

Definition

Name
Util.flash
Shorthand
u.flash
Syntax
Node = Util.flash( Node node, String url [, JSON settings ] );

Description

Create a flash object and inject it as firstChild in node.

Parameters

node
Node node to inject flash object into
url
String path to .swf file
settings
JSON Optional, JSON object with flash object settings
Options
id
id attribute of flash object - default is auto generated
width
width attribute of flash object - default 100%
height
height attribute of flash object - default 100%
background
background attribute of flash object - default transparent
allow­Script­Access
allow­Script­Access attribute of flash object - default always
menu
menu attribute of flash object - default false
scale
scale attribute of flash object - default showall
wmode
wmode attribute of flash object - default transparent

Returns

Node flash object node

Examples

<div class="scene"></div> <script> var scene = u.qs(".scene"); u.flash(scene, "/flash.swf"); </script>

Returns the object node injected into div.scene

Uses

JavaScript
  • Date
  • document.createElement
  • document.insertBefore
  • switch ... case
Manipulator
  • Util.explorer
  • Util.querySelector

Files

Main file

  • u-flash.js

Segment support files

  • none

Segment dependencies

desktop_edge
u-flash.js + u-system.js + u-dom.js
desktop_ie11
u-flash.js + u-system.js + u-dom.js
desktop
u-flash.js + u-system.js + u-dom.js
desktop_ie10
u-flash.js + u-system.js + u-dom.js
desktop_ie9
u-flash.js + u-system.js + u-dom.js
desktop_light
u-flash.js + u-system.js + u-dom.js + u-dom-desktop_light.js
tablet
u-flash.js + u-system.js + u-dom.js
tablet_light
u-flash.js + u-system.js + u-dom.js
smartphone
u-flash.js + u-system.js + u-dom.js
mobile
not tested
mobile_light
not tested
tv
u-flash.js + u-system.js + u-dom.js + u-dom-desktop_light.js
seo
not supported