Exemple #1
0
<?php

/**
 * Implementation of the Application Packaging Standard from SwSoft/Parallels
 * http://apsstandard.com.
 *
 * Copyright (c) 2003-2009 the SysCP Team (see authors).
 *
 * For the full copyright and license information, please view the COPYING
 * file that was distributed with this source code. You can also view the
 * COPYING file online at http://files.syscp.org/misc/COPYING.txt
 *
 * @copyright	(c) the authors
 * @author		Sven Skrabal <*****@*****.**>
 * @license		GPLv2 http://files.syscp.org/misc/COPYING.txt
 *
 * @version		$Id$
 *
 * @todo
 */
$needrootdb = true;
require dirname(__FILE__) . '/../lib/cron_init.php';
$Aps = new ApsInstaller($settings, $db, $db_root);
$Aps->InstallHandler();
require dirname(__FILE__) . '/../lib/cron_shutdown.php';
 /**
  * Uninstall an instance
  */
 public function delete($event_name, $data)
 {
     global $app, $conf;
     if (!isset($data['new']['id'])) {
         return false;
     }
     $instanceid = $data['new']['id'];
     if ($data['new']['instance_status'] == INSTANCE_REMOVE) {
         $aps = new ApsInstaller($app);
         $aps->installHandler($instanceid, 'install');
     }
 }