Location: PHPKode > scripts > FuseBox Manager > fusebox-manager/src/fusebox4.core/fusebox4.application.php4.php
<?
// copy all FORM and URL variables to ATTRIBUTES scope
// here, FORM has precendence although this can be over-written later depending on the application's fusebox.xml setting.
if(!isset($attributes) || !is_array($attributes))
{
  $attributes = array();
  $attributes = array_merge($_GET,$_POST); 
}

if (isset($attributes['language']))
  $_SESSION['language'] = $attributes['language'];

if (isset($attributes['country']))
{
  $_SESSION['country'] = substr($attributes['country'],0,3);
}
else
{
  if (!isset($_SESSION['country']))
    $_SESSION['country'] = "WW";
}

if (isset($attributes['currency']))
  $_SESSION['currency'] = substr($attributes['currency'],0,3);
else
  if (!isset($_SESSION['currency']))
    $_SESSION['currency'] = 'EUR';

//returns Circuit of the Fuseaction, e.g.
//"home" from "home.main"
function getCircuit($fa)
{
  $circuit = "";
  $fa = explode(".", $fa);
  $circuit = array_shift($fa);
  return $circuit;
}

//returns Fuse of the Fuseaction, e.g.
//"main" from "home.main"
function getFuse($fa)
{
  $fuse = "";
  $fa = explode(".", $fa);
  $fuse = array_pop($fa);
  return $fuse;
}

//returns unnecessary spaces from html
function optimize_html($str)
{
  $str = ereg_replace("[[:space:]]{2,}"," ", $str);
  $str = ereg_replace(">[[:space:]]+<","><", $str);
  return $str;
}
?>
Return current item: FuseBox Manager