Hanno Böck To the extent possible under law, the author(s) have dedicated all copyright and related and neighboring rights to this software to the public domain worldwide. This software is distributed without any warranty. You should have received a copy of the CC0 Public Domain Dedication along with this software. If not, see http://creativecommons.org/publicdomain/zero/1.0/ Nevertheless, in case you use a significant part of this code, we ask (but not require, see the license) that you keep the authors' names in place and return your changes to the public. We would be especially happy if you tell us what you're going to do with this code. */ require_once('inc/debug.php'); require_once('inc/security.php'); require_once('inc/icons.php'); require_once('vhosts.php'); title("Subdomains"); $error = ''; require_role(ROLE_SYSTEMUSER); global $prefix; output("

Mit dieser Funktion legen Sie fest, welche Domains und Subdomains als Webserver-Ressource verfügbar sein sollen und welches Verzeichnis die Dateien enthalten soll.

Änderungen an Ihren Einstellungen werden im 5-Minuten-Takt auf dem Server übernommen.

"); $vhosts = list_vhosts(); $traffic_sum = 0; if (count($vhosts) > 0) { if (count($vhosts) > 10) { addnew('edit', 'Neue Domain bzw. Subdomain einrichten'); addnew('../webapps/install', 'Neue Domain bzw. Subdomain mit vorinstallierter Web-Anwendung einrichten'); } output("\n"); $even = True; foreach ($vhosts as $vhost) { $even = ! $even; $fqdn = $vhost['fqdn']; $class = 'odd'; if ($even) $class = 'even'; output("'); $logfiles = 'Kein Log'; if ($vhost['logtype'] == 'default') $logfiles = 'Zugriffe '; elseif ($vhost['logtype'] == 'anonymous') $logfiles = 'Anonym'; if ($vhost['errorlog'] == 1) { if ($vhost['logtype'] == NULL) $logfiles = 'Fehler'; else $logfiles .= ' + Fehler'; } $stats = $vhost['stats'] ? internal_link("showstats", other_icon("chart_bar.png", "Statistiken anzeigen"), "vhost={$vhost['id']}").' ' : ''; output(""); if ($vhost['ssl'] == 'http') { output(""); } elseif ($vhost['cert']) { output(""); } else { output(""); } $traffic = traffic_month($vhost['id']); $traffic_sum += (int) $traffic; $traffic_string = $traffic.' MB'; if ($traffic > 1024) { $traffic_string = round($traffic / 1024, 2).' GB'; } if ($traffic === NULL) { $traffic_string = '--'; } output(""); if ($vhost['is_webapp'] == 1) { output(''); } elseif ($vhost['is_dav'] == 1) { output(''); } elseif ($vhost['is_svn'] == 1) { output(''); } else { $php = $vhost['php']; switch ($php) { case NULL: $php = icon_disabled('PHP ausgeschaltet'); break; case 'mod_php': $php = icon_warning('[mod_php] Veraltet, bitte umstellen!').' Apache-Modul'; break; case 'fastcgi': $php = icon_enabled_warning('PHP in veralteter Version aktiviert'); break; case 'php53': $php = icon_enabled_php53('PHP in Version 5.3 eingeschaltet'); break; case 'php54': $php = icon_enabled_php54('PHP in Version 5.4 eingeschaltet'); break; case 'php55': $php = icon_enabled_php55('PHP in Version 5.5 eingeschaltet'); break; } output(""); if ($vhost['docroot_is_default'] == 1) output(""); else output(""); } output("\n"); } output('
(Sub-)DomainZusätzliche Alias-NamenProtokollSSLTraffic*PHPLokaler Pfad**
".internal_link('edit', $fqdn, "vhost={$vhost['id']}", 'title="Einstellungen bearbeiten"')."".internal_link('save', icon_delete("»{$vhost['fqdn']}« löschen"), 'action=delete&vhost='.$vhost['id'] ).""); $aliases = get_all_aliases($vhost); $tmp = ''; if (count($aliases) > 0) { foreach ($aliases as $alias) { $tmp .= $alias['fqdn'].'
'; } } else { $tmp = '- keine -'; } output(internal_link('aliases', $tmp, 'vhost='.$vhost['id'], 'title="Aliase verwalten"')); output('
{$stats}{$logfiles}".icon_disabled('SSL ausgeschaltet')."\"cert\"".icon_enabled('SSL eingeschaltet')."{$traffic_string}Sonderanwendung: Vorinstallierte WebanwendungSonderanwendung: WebDAVSonderanwendung: Subversion-Server{$php}{$vhost['docroot']}{$vhost['docroot']}
'); if ($traffic_sum > 0) { $traffic_string = $traffic_sum.' MB'; if ($traffic_sum > 1024) { $traffic_string = round($traffic_sum / 1024, 2).' GB'; } output('

Traffic insgesamt: '.$traffic_string.' in den lezten 30 Tagen

'); } output('

*) Dieser Wert stellt den Datenverkehr dieser Website für die letzten 30 Tage dar.

'); output('

**) schwach geschriebene Pfadangaben bezeichnen die Standardeinstellung. Ist ein Pfad fett dargestellt, so haben Sie einen davon abweichenden Wert eingegeben.

'); } else // keine VHosts vorhanden { output("

Bisher haben Sie keine Domain bzw. Subdomain eingerichtet.

"); } addnew('edit', 'Neue Domain bzw. Subdomain einrichten'); addnew('../webapps/install', 'Neue Domain bzw. Subdomain mit vorinstallierter Web-Anwendung einrichten'); ?>