public function __construct() { $this->defaults = parse_ini_file('application.ini', true); PHPApplication::$application = $this; if (isset($this->defaults['application']['delegate'])) { $this->delegate = new $this->defaults['application']['delegate'](); $this->delegate->applicationDidFinishLaunching(); } $this->handleRequest(); }
public static function CodeBehind($class, &$control, &$argv) { // spl_object_hash() // argv and argc are reserved in PHP, but this concept is the same. $argc = count($argv); $application = PHPApplication::sharedApplication(); require $_SERVER['DOCUMENT_ROOT'] . "/application/controls/" . $class; $class = substr($class, 0, strrpos($class, '.')); $control = new $class($argc, $argv); }
public function __construct() { PHPApplication::$application = $this; new PHPApplicationSettings(); $this->settings = PHPApplicationSettings::sharedSettings(); if (isset($this->settings['application']['delegate'])) { $this->delegate = new $this->settings['application']['delegate'](); if ($this->delegate && method_exists($this->delegate, 'applicationDidFinishLaunching')) { $this->delegate->applicationDidFinishLaunching(); } } $this->handleRequest(); }
function ChangeUser($params) { PHPApplication::PHPApplication($params); }
function Admin($params) { PHPApplication::PHPApplication($params); }
function sampleApp($params) { PHPApplication::PHPApplication($params); }