/**
  * process a request
  *
  * @param $args
  * @return mixed
  */
 function processRequest($args)
 {
     global $instanceFluxCLI;
     // create new instance
     $instanceFluxCLI = new FluxCLI($args);
     // call instance-method
     return !$instanceFluxCLI ? false : $instanceFluxCLI->instance_processRequest();
 }
Example #2
0
    die;
}
if (isset($_REQUEST['argv'])) {
    die;
}
// dummy
$_SESSION = array('cache' => false);
/******************************************************************************/
// change to docroot if needed
if (!is_file(realpath(getcwd() . '/inc/main.core.php'))) {
    chdir(realpath(dirname(__FILE__) . "/.."));
}
// check for home
if (!is_file('inc/main.core.php')) {
    exit("Error: this script can only be used in its default-path (DOCROOT/bin/)\n");
}
// main.core
require_once 'inc/main.core.php';
// all functions
require_once 'inc/functions/functions.all.php';
// FluxCLI-class
require_once 'inc/classes/FluxCLI.php';
// load default-language
loadLanguageFile($cfg["default_language"]);
// transfers-array
initGlobalTransfersArray();
// Fluxd
Fluxd::initialize();
// FluxCLI
FluxCLI::processRequest($argv);