Example #1
0
 function __construct()
 {
     $path = dirname(__FILE__);
     // $path = '/home/content/50/6934650/html/';
     $onlineMode = false;
     if (stripos($path, '/home/content/50/6934650/html/') !== false) {
         $onlineMode = true;
     }
     if (!defined('ONLINEMODE')) {
         define('ONLINEMODE', $onlineMode);
     }
     if (!isset(self::$ConfigParser)) {
         self::$ConfigParser = new ConfigParser();
     }
     if (!isset(self::$DBConnection)) {
         $this->reconnectDB();
     }
     if (!isset(self::$CommandLineHelper)) {
         self::$CommandLineHelper = new CommandLineHelper(self::$DBConnection);
     }
     if (!isset(self::$Logger)) {
         self::$Logger = new LogHelper();
     }
     if (ONLINEMODE) {
         $this->notifyDBOfTask();
     }
     $this->constructClass();
     if (ONLINEMODE) {
         $this->notifyDBOfTaskFinished();
     }
     echo " ";
 }
Example #2
0
 function __construct()
 {
     if (!isset(self::$ConfigParser)) {
         self::$ConfigParser = new ConfigParser();
     }
     if (!isset(self::$DBConnection)) {
         $this->reconnectDB();
     }
     if (!isset(self::$CommandLineHelper)) {
         self::$CommandLineHelper = new CommandLineHelper();
     }
     if (!isset(self::$Logger)) {
         self::$Logger = new LogHelper();
     }
     $this->constructClass();
 }