Esempio n. 1
0
 /**
  *	Assign the correct plugin ID and call the parent constructor
  *	@constructor
  */
 public function __construct()
 {
     // configure this plugin
     $this->_info = array('id' => basename(__FILE__, '.php'), 'name' => 'Contact Form', 'version' => '1.0', 'author' => 'RJ Zaworski <*****@*****.**>', 'author_website' => 'http://rjzaworski.com/', 'description' => 'A Contact Link', 'page_type' => 'theme', 'menu_callback' => 'admin_view');
     // initiate the plugin
     parent::__construct();
 }
Esempio n. 2
0
 /**
  *	Assign the correct plugin ID and call the parent constructor
  *	@constructor
  */
 public function __construct()
 {
     // by default, use today's date for scheduling
     $this->_defaults['schedule_start'] = date('m/j/y');
     // configure this plugin
     $this->_info = array('id' => basename(__FILE__, '.php'), 'name' => 'Cloud Backup', 'version' => '1.0', 'author' => 'RJ Zaworski <*****@*****.**>', 'author_website' => 'http://rjzaworski.com/', 'description' => 'Automated remote backups', 'page_type' => 'backups', 'menu_callback' => 'admin_view');
     // initiate the plugin
     parent::__construct();
     // build provider, if one is selected
     if (isset($this->_settings['provider'])) {
         $class_name = 'CloudBackup\\Providers\\' . ucfirst($this->_settings['provider']);
         $this->provider = new $class_name($this);
     }
     // build backup strategy, if one is selected
     if (isset($this->_settings['archiver'])) {
         $class_name = 'CloudBackup\\Archivers\\' . ucfirst($this->_settings['archiver']);
         $this->archiver = new $class_name($this);
     }
     // build scheduler
     $this->scheduler = new CloudBackup\Scheduler($this);
     // build notifier
     $this->notifier = new CloudBackup\Notifier($this);
 }