Ejemplo n.º 1
0
 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();
 }
Ejemplo n.º 2
0
 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);
 }
Ejemplo n.º 3
0
 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();
 }
Ejemplo n.º 4
0
 function ChangeUser($params)
 {
     PHPApplication::PHPApplication($params);
 }
Ejemplo n.º 5
0
 function Admin($params)
 {
     PHPApplication::PHPApplication($params);
 }
Ejemplo n.º 6
0
 function sampleApp($params)
 {
     PHPApplication::PHPApplication($params);
 }