/**
  * Constructor
  *
  * @access     public
  * @return     void
  */
 public function __construct()
 {
     // Call parent constructor
     parent::__construct();
     // Set class name
     $this->class_name = ucfirst(LOW_VAR_PACKAGE);
 }
Example #2
0
 /**
  * Constructor
  *
  * @access     public
  * @param      mixed
  * @return     void
  */
 public function __construct($settings = array())
 {
     // Call Base constructor
     parent::__construct();
     // Assign current settings
     $this->settings = array_merge($this->default_settings, $settings);
     // And overwite given settings with the ones defined in config.php
     $this->apply_config_overrides();
 }
Example #3
0
 /**
  * Constructor
  *
  * @access     public
  * @return     void
  */
 public function __construct()
 {
     // -------------------------------------
     //  Call parent constructor
     // -------------------------------------
     parent::__construct();
     // -------------------------------------
     //  Get settings from extension, cache or DB
     // -------------------------------------
     if ($this->get_settings()) {
         $this->data['settings'] = $this->settings;
     } else {
         $this->error_msg = lang('settings_not_found');
         return;
     }
     // -------------------------------------
     //  Define base url for module
     // -------------------------------------
     $this->set_base_url();
     // -------------------------------------
     //  License check.
     //  Removing this makes baby Jesus cry
     // -------------------------------------
     if (!$this->_license()) {
         return;
     }
     // -------------------------------------
     //  Include variable types
     // -------------------------------------
     $this->_include_types();
     // -------------------------------------
     //  Sync tables
     // -------------------------------------
     $this->_sync();
     // -------------------------------------
     //  Define URLS
     // -------------------------------------
     $this->data['show_group_url'] = $this->base_url . AMP . 'group_id=%s';
     $this->data['edit_var_url'] = $this->base_url . AMP . 'method=manage&id=%s&from=%s';
     $this->data['edit_group_url'] = $this->base_url . AMP . 'method=edit_group&id=%s&from=%s';
     $this->data['del_group_url'] = $this->base_url . AMP . 'method=del_group_conf&id=%s';
 }