예제 #1
0
 function __construct($app)
 {
     # Get ip address
     $this->ipaddress = s2GetIpAddress();
     $this->app = $app;
     # Load models
     $this->__initModels();
     parent::__construct();
 }
예제 #2
0
 function __construct($app = 'jreviews')
 {
     parent::__construct();
     if (!empty($this->helpers)) {
         $this->app = $app;
         App::import('Helper', $this->helpers, $this->app);
         foreach ($this->helpers as $helper) {
             $method_name = inflector::camelize($helper);
             $class_name = $method_name . 'Helper';
             if (!isset($this->loaded[$method_name])) {
                 $this->{$method_name} = ClassRegistry::getClass($class_name);
                 $this->loaded[$method_name] =& ${$method_name};
             }
         }
     }
 }
예제 #3
0
 function __construct($app)
 {
     global $Itemid, $mosConfig_sef, $mosConfig_lang;
     cmsFramework::init($this);
     if (isset($this->xajax) && $this->xajax == true) {
         $this->loadXajax();
     }
     /****************** THIS BLOCK CAN PROBABLY BE DELETED ******************/
     $this->language = $mosConfig_lang;
     $this->itemid = $Itemid;
     $this->sef = $mosConfig_sef;
     /****************** THIS BLOCK CAN PROBABLY BE DELETED ******************/
     # Get ip address
     $this->ipaddress = s2GetIpAddress();
     $this->app = $app;
     # Load models
     $this->__initModels();
     parent::__construct();
 }
예제 #4
0
 function __construct(&$controller, $register = true)
 {
     if (is_object($controller)) {
         $count = count($this->__passedVars);
         for ($j = 0; $j < $count; $j++) {
             if (isset($this->__passedVars[$j]) && isset($controller->{$this->__passedVars[$j]})) {
                 $var = $this->__passedVars[$j];
                 $this->{$var} = $controller->{$var};
             }
         }
     }
     //		$inAdmin = $this->inAdmin = defined('MVC_FRAMEWORK_ADMIN') ? true : false;
     $theme = Configure::read('Theme.name', 'default');
     if (!isset($this->viewImages)) {
         $this->viewImagesPath = S2Object::locateThemeFile('.info', 'path', '') . 'theme_images' . DS;
         $this->viewImages = pathToUrl($this->viewImagesPath);
     }
     parent::__construct();
     /*		if ($register) {
     			ClassRegistry::addObject('view', $this);
     		}		*/
 }
예제 #5
0
파일: folder.php 프로젝트: bizanto/Hooked
 /**
  * Constructor.
  *
  * @param string $path Path to folder
  * @param boolean $create Create folder if not found
  * @param mixed $mode Mode (CHMOD) to apply to created folder, false to ignore
  */
 function __construct($path = false, $create = false, $mode = false)
 {
     parent::__construct();
     if (empty($path)) {
         $path = S2Paths::get('jreviews', 'S2_TMP');
     }
     if ($mode) {
         $this->mode = $mode;
     }
     if (!file_exists($path) && $create === true) {
         $this->create($path, $this->mode);
     }
     if (!Folder::isAbsolute($path)) {
         $path = realpath($path);
     }
     if (!empty($path)) {
         $this->cd($path);
     }
 }
예제 #6
0
파일: l10n.php 프로젝트: bizanto/Hooked
 /**
  * Class constructor
  */
 function __construct()
 {
     if (defined('DEFAULT_LANGUAGE')) {
         $this->default = DEFAULT_LANGUAGE;
     }
     parent::__construct();
 }
예제 #7
0
 function __construct()
 {
     # Adds CMS DB and Mainframe methods
     $this->_db =& cmsFramework::getDB();
     parent::__construct();
 }
예제 #8
0
파일: file.php 프로젝트: bizanto/Hooked
 /**
  * Constructor
  *
  * @param string $path Path to file
  * @param boolean $create Create file if it does not exist (if true)
  * @param integer $mode Mode to apply to the folder holding the file
  * @access private
  */
 function __construct($path, $create = false, $mode = 0755)
 {
     parent::__construct();
     $this->Folder = new Folder(dirname($path), $create, $mode);
     if (!is_dir($path)) {
         $this->name = basename($path);
     }
     $this->pwd();
     if (!$this->exists()) {
         if ($create === true) {
             if ($this->safe($path) && $this->create() === false) {
                 return false;
             }
         } else {
             return false;
         }
     }
 }
예제 #9
0
 /**
  * Constructor
  *
  * @access private
  */
 function __construct()
 {
     $this->overload();
     parent::__construct();
 }
예제 #10
0
파일: model.php 프로젝트: bizanto/Hooked
 function __construct()
 {
     # Adds CMS DB and Mainframe methods
     cmsFramework::init($this);
     parent::__construct();
 }