Пример #1
0
     }
     $sys = ZSystem::getSettings();
     $tpl_dir = ZH . "/tpl";
     $d = dir($tpl_dir);
     $themes = array();
     while ($f = $d->read()) {
         $param_file = "{$tpl_dir}/{$f}/param.ini";
         if (!is_file($param_file)) {
             continue;
         }
         $param = parse_ini_file($param_file);
         $themes[] = (object) $param;
     }
     break;
 case 'sync':
     syncSystemUsers();
     syncFtpUsers();
     syncVhosts();
     syncCBand();
     syncCrontab();
     setmsg(t('All data updated!'), 'notice');
     break;
 case 'ctl':
     if (!isadmin()) {
         setmsg(t('Permission Denied'));
     }
     $a = strtolower($_REQUEST['a']);
     // Application
     $o = $_REQUEST['o'];
     // Operation
     if ($a == 'apache' && in_array($o, array('start', 'stop', 'restart'))) {
Пример #2
0
function sync()
{
    syncFtpUsers();
    syncVhosts();
    syncCBand();
    syncSystemUsers();
    syncCrontab();
    syncQuota();
}