| 1 |
<?php |
| 2 |
/** |
| 3 |
* |
| 4 |
*/ |
| 5 |
|
| 6 |
// Disallow direct access. |
| 7 |
defined('ABSPATH') or die("Access denied"); |
| 8 |
|
| 9 |
// import dependencies. |
| 10 |
cssJSToolbox::import('framework:mvc:controller-ajax.inc.php'); |
| 11 |
|
| 12 |
/** |
| 13 |
* |
| 14 |
*/ |
| 15 |
class CJTInstallerController extends CJTAjaxController { |
| 16 |
|
| 17 |
/** |
| 18 |
* put your comment there... |
| 19 |
* |
| 20 |
* @var mixed |
| 21 |
*/ |
| 22 |
protected $controllerInfo = array('model' => 'installer'); |
| 23 |
|
| 24 |
/** |
| 25 |
* put your comment there... |
| 26 |
* |
| 27 |
*/ |
| 28 |
public function __construct() { |
| 29 |
parent::__construct(); |
| 30 |
// Register actions! |
| 31 |
$this->registryAction('install'); |
| 32 |
$this->registryAction('dismissNotice'); |
| 33 |
} |
| 34 |
|
| 35 |
/** |
| 36 |
* put your comment there... |
| 37 |
* |
| 38 |
*/ |
| 39 |
public function dismissNoticeAction() { |
| 40 |
$this->model->dismissNotice(true); |
| 41 |
$this->response = true; |
| 42 |
} |
| 43 |
|
| 44 |
/** |
| 45 |
* put your comment there... |
| 46 |
* |
| 47 |
*/ |
| 48 |
protected function installAction() { |
| 49 |
// Get model object! |
| 50 |
$model =& $this->model; |
| 51 |
// Installa requested operation. |
| 52 |
$input['operation'] = $_REQUEST['operation']; |
| 53 |
$this->response = $model->setInput($input)->install(); |
| 54 |
} |
| 55 |
|
| 56 |
} // End class. |
| 57 |
|