You are here

function simpleviewer_swftools_flashvars in SWF Tools 5

Same name and namespace in other branches
  1. 6 simpleviewer/simpleviewer.module \simpleviewer_swftools_flashvars()
  2. 6.2 simpleviewer/simpleviewer.module \simpleviewer_swftools_flashvars()

Implementation of swftools_flashvars hook Allows the Flash player provider to add variables to the Flashvars array. Other arrays can also be modified.

File

simpleviewer/simpleviewer.module, line 63

Code

function simpleviewer_swftools_flashvars($action, &$methods, &$vars) {
  $sv_vars = _simpleviewer_vars(TRUE);

  // Here we only assign 'other' settings to othervars, and return 'swf' settings
  // as the flashvars. 'xml' settings are for the xml file only.
  // See http://www.airtightinteractive.com/forum/viewtopic.php?t=4085&start=0
  if (is_array($sv_vars['other'])) {
    $vars->othervars = array_merge($sv_vars['other'], $vars->othervars);
  }
  return $sv_vars['swf'];
}