".$_SESSION['http_host_extended'];
if ( $_SESSION['http_host_extended'] != $http_host_extended ) {
unset($_SESSION[$_SESSION['http_host_extended']]['menu_aktiv']);
//if ( $_SESSION[$_SESSION['http_host_extended']]['users']['rang'] > 1 ) {
//unset($_SESSION[$_SESSION['http_host_extended']]['users']);
//}
$_SESSION['http_host_extended'] = $http_host_extended;
}
//echo $_SERVER['PHP_SELF'];
//ini_set("session.use_trans_sid", "0"); // schaltet die SID übergabe per GET Parameter AUS
ini_set('url_rewriter.tags', '');
if ( !$php_self ) {
$php_self = $_SERVER['PHP_SELF'];
}
$menu_temp['id_daten'] = array();
$menu['id_daten'] = array();
// Zeitmessung beginnen
$time_start = microtime_float();
//$used = "log/used.txt";
//if ( !file_exists($used) ) {
// $file = fopen($used,'wb');
// fwrite($file,"");
// fclose($file);
//}
//$used_content = file_get_contents($used);
//reset_used();
$writing = "log/writing.txt";
if ( !file_exists($writing) ) {
$file = fopen($writing,'wb');
fwrite($file,"");
fclose($file);
}
//echo $_SERVER['PHP_SELF'];
$heute = getdate();
foreach($heute as $item=>$value) {
if ($value < 10)
$heute[$item] = "0".$value;
}
$server_names_ignore = array ( "quadrart.dnsalias.com","www.quadrart.dnsalias.com","server","shuttle","192.168.9.1");
// POST-Variablen auslesen
//echo $action;
if ($post) {
$post = get_post($post);
foreach ($post as $post_key => $post_value) {
$post[$post_key] = $post_value;
if ( $post_value and !isset($$post_key) ) {
if ( substr_count($post_key,"[") > 0 and substr_count($post_key,"]") > 0 ) {
//$replace_var = ereg_replace("(.*)[(.*)](.*)","\\1",$post_key);
$replace_var = ereg_replace("\[(.*)\]","",$post_key);
$replace_key = ereg_replace("(.*)\[(.*)\](.*)","\\2",$post_key);
${$replace_var}[$replace_key] = $post_value;
//echo "REPLACE: ".$replace_var."[".$replace_key."]";
} else {
$$post_key = $post_value;
}
//echo $post_key." ---> ".$post_value."
";
//echo $temp[shop];
}
}
}
//echo $open;
//echo $down_id;
// prev erstellen
//if ( $_SESSION[$_SESSION['http_host_extended']]['users']['rang'] < 99 ) { echo ""; print_r($post); echo "
"; }
//echo "
index -> "; print_r($post); echo "
";
// Basis-Grundeinstellungen
$daten_pfad="daten/";
$includes="includes/";
$datenbank_suffix = ".oli";
$line_feed=substr(file_get_contents($daten_pfad."menu.oli"),0,1);
$lf = "
";
// Rewrite setzetn
//if ( !is_numeric($open) ) {
$mod_rewrite = reader("rewrite");
foreach ( $mod_rewrite['id_daten'] as $mod_key => $mod_value ) {
$mod_key = explode("-",$mod_key);
if ( $mod_value['REWRITE'] == $open ) {
$open = $mod_key[0];
$lang = $mod_key[1];
$_SESSION[$_SESSION['http_host_extended']]['language_symbol'] = $lang;
$_SESSION[$_SESSION['http_host_extended']]['language'] = $languages[$lang];
//echo $_SESSION[$_SESSION['http_host_extended']]['language'];
break;
}
}
//}
// Weitere Grundeinstellungen aus Datenbank laden
$einstellungen=reader('einstellungen');
// Sprache einstellen
$multilanguage = $einstellungen['id_daten'][0]['WERT'];
if ( !$multilanguage ) {
$multilanguage = "LANG_0,de,deutsch";
}
$multilanguage = explode("//",$multilanguage);
foreach ($multilanguage as $key => $value) {
$language_settings = explode(",",$value);
$languages[$language_settings[1]] = $language_settings[0];
if ( $language_settings[0] == "LANG_0" and !$standard_language ) {
$standard_language = $language_settings[1];
}
}
//echo $_SERVER['HTTP_ACCEPT_LANGUAGE'];
if ( !$_SESSION[$_SESSION['http_host_extended']]['language'] ) {
$http_accept_languages = explode(",",$_SERVER['HTTP_ACCEPT_LANGUAGE']);
foreach ($http_accept_languages as $key => $value) {
$http_accept_language = explode(";",$value);
$http_accept_language = $http_accept_language[0];
$http_accept_language = explode("-",$http_accept_language);
if ( $http_accept_language[1] ) {
$http_accept_language = strtolower($http_accept_language[1]);
} else {
$http_accept_language = strtolower($http_accept_language[0]);
}
unset($http_accept_languages[$key]);
$http_accept_languages[$http_accept_language] = $languages[$http_accept_language];
}
$http_accept_languages = array_intersect($http_accept_languages,$languages);
//echo ""; print_r($http_accept_languages); echo "
";
reset($http_accept_languages);
if ( !$lang or !array_key_exists($lang,$languages) ) {
$lang = key($http_accept_languages);
}
if ( !$lang ) {
$lang = $standard_language;
}
}
if ( !$_SESSION[$_SESSION['http_host_extended']]['language'] ) {
$_SESSION[$_SESSION['http_host_extended']]['language'] = 'LANG_0';
$_SESSION[$_SESSION['http_host_extended']]['language_symbol'] = 'de';
}
if ( $lang ) {
//if ( !$languages[$lang] ) {
//$languages[$lang] = "LANG_0";
//}
$_SESSION[$_SESSION['http_host_extended']]['language'] = $languages[$lang];
$_SESSION[$_SESSION['http_host_extended']]['language_symbol'] = $lang;
}
if ( $_SESSION[$_SESSION['http_host_extended']]['users']['rang'] < 99 ) {
//echo ""; print_r($languages); echo "
";
}
foreach($einstellungen['id_daten'] as $key => $value) {
if ($einstellungen['id_daten'][$key]['VARIABLE'] != "" and $einstellungen['id_daten'][$key][$_SESSION[$_SESSION['http_host_extended']]['language']]) {
${$einstellungen['id_daten'][$key]['VARIABLE']}=$einstellungen['id_daten'][$key][$_SESSION[$_SESSION['http_host_extended']]['language']];
if ( $einstellungen['id_daten'][$key]['ALL_LANG'] ) {
${$einstellungen['id_daten'][$key]['VARIABLE']."_all"}['LANG_0'] = $einstellungen['id_daten'][$key]['WERT'];
${$einstellungen['id_daten'][$key]['VARIABLE']."_all"}['LANG_1'] = $einstellungen['id_daten'][$key]['LANG_1'];
${$einstellungen['id_daten'][$key]['VARIABLE']."_all"}['LANG_2'] = $einstellungen['id_daten'][$key]['LANG_2'];
${$einstellungen['id_daten'][$key]['VARIABLE']."_all"}['LANG_3'] = $einstellungen['id_daten'][$key]['LANG_3'];
}
} else {
${$einstellungen['id_daten'][$key]['VARIABLE']}=$einstellungen['id_daten'][$key]['WERT'];
if ( $einstellungen['id_daten'][$key]['ALL_LANG'] ) {
${$einstellungen['id_daten'][$key]['VARIABLE']."_all"}['LANG_0'] = $einstellungen['id_daten'][$key]['WERT'];
${$einstellungen['id_daten'][$key]['VARIABLE']."_all"}['LANG_1'] = $einstellungen['id_daten'][$key]['LANG_1'];
${$einstellungen['id_daten'][$key]['VARIABLE']."_all"}['LANG_2'] = $einstellungen['id_daten'][$key]['LANG_2'];
${$einstellungen['id_daten'][$key]['VARIABLE']."_all"}['LANG_3'] = $einstellungen['id_daten'][$key]['LANG_3'];
}
}
}
if (!isset ($_SESSION[$_SESSION['http_host_extended']]['users'])) {
$_SESSION[$_SESSION['http_host_extended']]['users']['name'] = 'anonym';
$_SESSION[$_SESSION['http_host_extended']]['users']['group_ids'] = 0;
$_SESSION[$_SESSION['http_host_extended']]['users']['id'] = 0;
$_SESSION[$_SESSION['http_host_extended']]['users']['rang'] = 99;
$_SESSION[$_SESSION['http_host_extended']]['users']['rabatt'] = 0;
}
//if (!isset ($_SESSION[$_SESSION['http_host_extended']]['gruppe'])) {$_SESSION[$_SESSION['http_host_extended']]['gruppe'] = 'j'; }
//if (!isset ($_SESSION[$_SESSION['http_host_extended']]['benutzer'])) {$_SESSION[$_SESSION['http_host_extended']]['benutzer'] = 'keiner'; }
//if (!isset ($_SESSION[$_SESSION['http_host_extended']]['user_id'])) {$_SESSION[$_SESSION['http_host_extended']]['user_id'] = 0; }
if ( !$_SESSION[$_SESSION['http_host_extended']]['counting_all'] ) {
//WH include ("includes/counter_all.php");
}
if ( $_SESSION[$_SESSION['http_host_extended']]['counting'] == "+" ) {
//include ("includes/counter.php");
//$first_call = "x";
//aufzeichnung_db('Seitenaufruf (session start)',$_SESSION[$_SESSION['http_host_extended']]['users']['id'],"start");
//aufzeichnung('Seitenaufruf (session start)',$_SESSION[$_SESSION['http_host_extended']]['users']['id'],"start");
}
if ( !$_SESSION[$_SESSION['http_host_extended']]['counting'] ) {
$_SESSION[$_SESSION['http_host_extended']]['counting'] = "+";
}
// Neues Zählermodul
if ( !$_SESSION[$_SESSION['http_host_extended']]['counting_new'] ) { $_SESSION[$_SESSION['http_host_extended']]['counting_new'] = "none"; }
if ( !$screen ) {
include ("includes/counter_new.php");
}
if ($temp_modul) { $modul=$temp_modul; }
if (!isset($log)) { $log=''; }
//if (!isset ($menu)) { $menu=0; }
if (!isset ($submenu)) $submenu="";
//if (!isset ($druck)) $druck="";
if (!isset ($page)) { $page=""; }
if (!isset ($action)) { $action=""; }
if (!isset ($edit)) { $edit=""; }
if (!isset ($rubrik)) { $rubrik=""; }
if (!isset($seminar)) { $seminar=""; }
if (!isset($id)) { $id=""; }
if (!isset($subname)) { $subname=""; }
if (!isset($area)) { $area=""; }
//if (!isset( $_SESSION[$_SESSION['http_host_extended']]['menu_aktiv'])) $_SESSION[$_SESSION['http_host_extended']]['menu_aktiv'] = 1;
// Passwort abfragen
if (isset($passwort)) { include ($includes."passwort.php"); }
// Sicherheitscheck
if (
$action
and $action!="newsletter-abo"
and $action!="kalender-reservierung"
and $action!="shop-reservierung"
and $action!="shop-bestellung"
and $action!="shop-kundendaten"
and $action!="shop-logout"
and $action!="shop-status"
and $action!="shop-remove"
and $action!="shop-option"
and $action!="shop-add"
and $action!="shop-edit_artikel"
and substr($action,0,12) != "shop-anfrage"
and $action!="system-suche"
and $action!="download-view"
and $action!="download-play"
and $action!="download-stop"
and $action!="system-sendmail"
and $action!="shop-paypal_true"
and $action!="shop-paypal_false"
and $action!="shop-view_PDF"
and $_SESSION[$_SESSION['http_host_extended']]['users']['name'] == "anonym"
) {
$modul = "fehler";
//echo $modul;
$fehler_nr = 1;
unset($action);
unset($open);
unset($id);
unset($prev_id);
unset($_SESSION[$_SESSION['http_host_extended']]['menu_aktiv']);
}
//$menu=reader('menu');
//include($includes."security-check.php");
//unset($menu);
// Daten speichern
if ($action and $action!="edit" and !$update_id ) {
include($includes."action.php");
}
// easyCMS Registrierung prüfen
//if ( URL_exists("http://register.quadrart.com/index.php") ) {
//include_once("http://register.quadrart.com/index.php?domain=".$_SESSION['http_host_extended']);
//}
// Wenn logout dann Variablen setzen auf logout
if ($log=="out" and $prev) {
aufzeichnung('LogOUT',$_SESSION[$_SESSION['http_host_extended']]['users']['id'],"logout");
if ( $_SESSION['shop'][$_SESSION['shop']['current']]['status'] == "admin" ) {
$_SESSION['shop'][$_SESSION['shop']['current']]['status'] = $_SESSION['shop'][$_SESSION['shop']['current']]['prev_status'];
}
unset($_SESSION['shop'][$_SESSION['shop']['current']]['admin_suche']);
$_SESSION[$_SESSION['http_host_extended']]['users']['id'] = 0;
$_SESSION[$_SESSION['http_host_extended']]['users']['group_ids'] = 0;
$_SESSION[$_SESSION['http_host_extended']]['users']['rang'] = 99;
$_SESSION[$_SESSION['http_host_extended']]['users']['rabatt'] = 0;
$menu=reader('menu');
$check_ids = array();
foreach ($menu['id_daten'] as $key_check => $value_check) {
if (pfad_extend($value_check['PFAD']) == substr(pfad_extend($_SESSION[$_SESSION['http_host_extended']]['menu_aktiv']['PFAD']),0,strlen(pfad_extend($value_check['PFAD'])))) {
array_push($check_ids,$key_check);
}
}
$zugriff['users'] = explode(",",$_SESSION[$_SESSION['http_host_extended']]['users']['group_ids']);
$zugriff['groups'] = explode(",",$_SESSION[$_SESSION['http_host_extended']]['users']['groups_active']);
foreach ($check_ids as $key_id => $value_id) {
$lesezugriff = explode(",",$menu['id_daten'][$value_id]['LESEZUGRIFF']);
$zugriffsgruppen_lesen = array_intersect ($lesezugriff, $zugriff['users'],$zugriff['groups']);
if (
(count($zugriffsgruppen_lesen) == 0 and !in_array("0",$lesezugriff))
or (!$menu['id_daten'][$value_id]['STATUS'] and $_SESSION[$_SESSION['http_host_extended']]['users']['rang'] > 3)
) {
$forbidden = "YES";
}
}
if ($forbidden) {
unset($_SESSION[$_SESSION['http_host_extended']]['menu_aktiv']);
unset($prev);
} else {
if ($prev) {
$prev = get_post($prev);
foreach ($prev as $prev_key => $prev_value) {
$prev[$prev_key] = $prev_value;
if ( $prev_value and !isset($$prev_key) ) {
if ( substr_count($prev_key,"[") > 0 and substr_count($prev_key,"]") > 0 ) {
$replace_var = ereg_replace("\[(.*)\]","",$prev_key);
$replace_key = ereg_replace("(.*)\[(.*)\](.*)","\\2",$prev_key);
${$replace_var}[$replace_key] = $prev_value;
} else {
$$prev_key = $prev_value;
}
}
}
}
}
}
// Aktive Usergruppe und aktiven User bestimmen
$usergroups = reader("benutzergruppen");
$user = reader("benutzer");
// Aktiven User bestimmen
if ($_SESSION[$_SESSION['http_host_extended']]['users']['id'] > 0) {
$user_id = $_SESSION[$_SESSION['http_host_extended']]['users']['id'];
$groups_this_user = explode(",",$user['id_daten'][$user_id]['GROUPS']);
foreach ($usergroups['id_daten'] as $key => $value) {
if (in_array($value['ID'],$groups_this_user)) {
$rang[$key] = $value['RANG'];
}
}
$_SESSION[$_SESSION['http_host_extended']]['users']['full_name'] = $user['id_daten'][$user_id]['VORNAME'];
if ($user['id_daten'][$user_id]['NACHNAME'] and $user['id_daten'][$user_id]['VORNAME']) {
$_SESSION[$_SESSION['http_host_extended']]['users']['full_name'].= " ".$user['id_daten'][$user_id]['NACHNAME'];
} else {
$_SESSION[$_SESSION['http_host_extended']]['users']['full_name'].= $user['id_daten'][$user_id]['NACHNAME'];
}
$_SESSION[$_SESSION['http_host_extended']]['users']['name'] = $user['id_daten'][$user_id]['NAME'];
$_SESSION[$_SESSION['http_host_extended']]['users']['mail'] = $user['id_daten'][$user_id]['MAIL'];
$_SESSION[$_SESSION['http_host_extended']]['users']['rang'] = min($rang);
$_SESSION[$_SESSION['http_host_extended']]['users']['group_ids'] = $user['id_daten'][$user_id]['GROUPS'];
$_SESSION[$_SESSION['http_host_extended']]['users']['rabatt'] = $user['id_daten'][$user_id]['RABATT'];
} else {
$_SESSION[$_SESSION['http_host_extended']]['users']['full_name'] = 'Anonymer Benutzer';
$_SESSION[$_SESSION['http_host_extended']]['users']['name'] = 'anonym';
$_SESSION[$_SESSION['http_host_extended']]['users']['rang'] = 99;
$_SESSION[$_SESSION['http_host_extended']]['users']['group_ids'] = 0;
}
// Aktive Usergruppen einlesen
foreach($usergroups['id_daten'] as $key => $value) {
if ($value['STATUS'] == "x") $usergroups_active[$key] = $value['ID'];
}
$_SESSION[$_SESSION['http_host_extended']]['users']['groups_active'] = implode(",",$usergroups_active);
// Data Editor Admin Zugriff aktualisieren
if ( $_SESSION[$_SESSION['http_host_extended']]['users']['rang'] == 1 and ($passwort or $pass) and $login_admin_access_renew) {
// .htpasswd Datei erzeugen
$zugriff['groups'] = explode(",",$_SESSION[$_SESSION['http_host_extended']]['users']['groups_active']);
$user = reader("benutzer");
foreach ( $user['id_daten'] as $key => $value ) {
$u_rang = array();
$groups = explode(",",$value['GROUPS']);
$zugriffsgruppen_lesen = array_intersect ($groups,$zugriff['groups']);
foreach ($usergroups['id_daten'] as $u_key => $u_value) {
if (in_array($u_value['ID'],$groups) and $u_value['STATUS'] ) {
$u_rang[$u_key] = $u_value['RANG'];
}
}
if ( count($u_rang) > 0 ) {
$u_rang = min($u_rang);
} else {
$u_rang = 99;
}
//echo $value['NAME'].""; print_r($u_rang); echo "
";
//if ( in_array("1",$groups) or in_array("2",$groups) ) {
if ( count($zugriffsgruppen_lesen) > 0 and $u_rang <=4 and $value['STATUS'] ) {
$htpasswd[$key] = $value['NAME'].":".$value['PASSWORT'];
}
}
$htpasswd = implode($lf,$htpasswd);
$file = "daten/.htpasswd";
$file=fopen($file,'wb');
fwrite($file,$htpasswd);
fclose($file);
$php_self = $_SERVER['PHP_SELF'];
$php_self = explode("/",$php_self);
unset ($php_self[(count($php_self)-1)]);
if ( !$php_self[0] ) {
unset( $php_self[0] );
}
$php_self = implode("/",$php_self);
if ( $php_self ) { $php_self.= "/"; }
$document_root = $_SERVER['DOCUMENT_ROOT'];
$document_root = explode("/",$document_root);
if ( !$document_root[(count($document_root)-1)] ) {
unset( $document_root[(count($document_root)-1)] );
}
$document_root = implode("/",$document_root);
if ( $document_root ) { $document_root.= "/"; }
$admin_access = "RewriteEngine off".$lf.$lf."AuthType Basic".$lf."AuthName \"easyCMS - Admin\"".$lf."AuthUserFile ".$document_root.$php_self."daten/.htpasswd".$lf."require valid-user";
$file=fopen("data-editor/.htaccess",'wb');
fwrite($file,$admin_access);
fclose($file);
//echo $admin_access;
}
// Ligaturen
//$ligaturen = array( "ff" => "ff", "fi" => "fi", "fl" => "fl", "ffi" => "ffi", "ffl" => "ffl", "st" => "st" );
$ligaturen = $ligaturen_ti = $ligaturen_sub = $ligaturen_text = array( "fi" => "fi", "fl" => "fl" );
// Google Webfonts laden
$webfonts = array();
if ( $google_webfonts ) {
$google_webfonts = explode( "/",$google_webfonts);
foreach ( $google_webfonts as $gw_key => $gw_value ) {
$gw_value = explode(":",$gw_value);
$webfonts[$gw_value[0]] = explode(",",$gw_value[1]);
}
ksort($webfonts);
}
if ( array_key_exists($menu_font,$webfonts) ) {
$ligaturen = array();
}
// Menüstruktur aufbauen
if ($modul == "fehler") { unset($prev); }
include($includes."menu.php");
if ($hintergrund_temp) { $hintergrundfarbe = ""; }
if ($modul == "fehler") { $_SESSION[$_SESSION['http_host_extended']]['menu_aktiv']['LAYOUT'] = $standardwerte; }
if ($menu_position == "head" and $head_content and $action != "edit" ) {
$menu_head = $menu_show;
$menu_show = "";
}
if ($menu_position == "head" ) {
$menu_position = "";
}
// Head und Styles einfügen
include($includes."head.php");
$logo_position = explode("_",$logo_position);
if( $seitenrand ) {
if ( $seitenrahmen ) { $seitenrahmen = explode(",",$seitenrahmen); }
if ( count($seitenrahmen) > 1 ) {
$border = "border-top:".$seitenrahmen[0]."px solid ".$rahmenfarbton.";";
if($seitenrahmen[1]) { $border.= "border-right:".$seitenrahmen[1]."px solid ".$rahmenfarbton.";"; }
if($seitenrahmen[2] and ($copyright_position != "bottom_border_center" or $_SESSION[$_SESSION['http_host_extended']]['users']['rang'] <= 2) ) { $border.= "border-bottom:".$seitenrahmen[2]."px solid ".$rahmenfarbton.";"; }
if($seitenrahmen[3]) { $border.= "border-left:".$seitenrahmen[3]."px solid ".$rahmenfarbton.";"; }
} else {
$border = "border:".$seitenrahmen[0]."px solid ".$rahmenfarbton;
$seitenrahmen[1] = $seitenrahmen[0];
$seitenrahmen[2] = $seitenrahmen[0];
$seitenrahmen[3] = $seitenrahmen[0];
}
//echo $menu_background_color;
$seitenrand_explode = explode(",",$seitenrand);
for ( $x=0; $x<4; $x++ ) {
if ($seitenrand_explode[$x] == "") { $seitenrand_explode[$x] = $seitenrand_explode[0]; }
}
if ( $seitenrand_explode[1] or $seitenrand_explode[3] ) {
$width = $gesamtbreite_voll = $gesamtbreite;
$bgcolor = "";
} else {
if ( is_numeric($gesamtbreite) ) { $gesamtbreite_voll = $gesamtbreite-$settings[1]-$settings[2]; }
if ( $gesamtbreite_voll and $v_v_festbreite ) { $gesamtbreite_voll = $gesamtbreite_voll-$v_v_festbreite; }
$width = "100%";
//$bgcolor = "bgcolor='$hintergrundfarbe'";
}
} else {
$width = "100%";
$copy_breite = $width;
$rahmenstyle = "";
if ( is_numeric($gesamtbreite) ) { $gesamtbreite_voll = $gesamtbreite-$settings[1]-$settings[2]; }
}
if ( $menu_color_fade_percent != $seitenfarbton and !$menu_position ) {
if ( $menu_color_top ) { $menu_background_color_all = $menu_color_top; }
if ( $menu_color_top == "x" ) { $menu_background_color_all = $hintergrundfarbe; }
$rahmenstyle = $border;
$rahmenstyle_plus = "padding:".$seitenrand_explode[0]."px ".$seitenrand_explode[1]."px ".$seitenrand_explode[2]."px ".$seitenrand_explode[3]."px; ";
} else {
if ( $menu_color_top ) { $menu_background_color_all = $menu_color_top; }
if ( $menu_color_top == "x" ) { $menu_background_color_all = $farben_fein[$seitenfarbton]; }
$rahmenstyle_plus = "padding:".$seitenrand_explode[0]."px ".$seitenrand_explode[1]."px ".$seitenrand_explode[2]."px ".$seitenrand_explode[3]."px; ";
//$rahmenstyle = "margin:".$seitenrand."px";
}
if ( !$seitenrand and $menu_color_mode != "trans") {
if (is_numeric($seitenfarbton) ) {
$logo_background_color = color_tune($hauptfarbe,$seitenfarbton);
} else {
$logo_background_color = $seitenfarbton;
}
}
if ( substr_count($menu_color_fade_percent,"#") > 0 ) {
$logo_background_color = $menu_color_fade_percent;
}
if ( $seitenrahmen and $menu_style == "v_v" and !$seitenrand) {
$seitenrahmen = explode(",",$seitenrahmen);
$trennlinienhoehe = 10;
for ( $x=0; $x<4; $x++ ) {
if (!$seitenrahmen[$x]) { $seitenrahmen[$x] = $seitenrahmen[0]; }
}
$rahmenstyle_04.= "border-left:".$seitenrahmen[3]."px solid ".$rahmenfarbton.";";
$rahmenstyle_04.= "border-top:".$seitenrahmen[0]."px solid ".$rahmenfarbton.";";
}
if ( ( $menu_color_fade_percent == $seitenfarbton or $menu_position == "outside") and $seitenrahmen and $seitenrand) {
$rahmenstyle_01.= "border-right:".$seitenrahmen[1]."px solid ".$rahmenfarbton.";";
$rahmenstyle_01.= "border-left:".$seitenrahmen[3]."px solid ".$rahmenfarbton.";";
if ( $menu_color_mode != "fade" ) {
$rahmenstyle_01.= "border-top:".$seitenrahmen[0]."px solid ".$rahmenfarbton.";";
}
//$rahmenstyle_01.= "border-bottom:".$seitenrahmen[2]."px solid ".$rahmenfarbton.";";
$rahmenstyle_02 = "border-right:".$seitenrahmen[1]."px solid ".$rahmenfarbton.";";
$rahmenstyle_02.= "border-left:".$seitenrahmen[3]."px solid ".$rahmenfarbton.";";
$rahmenstyle_02.= "border-bottom:".$seitenrahmen[2]."px solid ".$rahmenfarbton.";";
if ( !$menu_show ) {
$rahmenstyle_02.= "border-top:".$seitenrahmen[0]."px solid ".$rahmenfarbton.";";
}
$rahmenstyle_03 = "border-bottom:".$seitenrahmen[2]."px solid ".$rahmenfarbton.";";
$rahmenstyle_03.= "border-left:".$seitenrahmen[3]."px solid ".$rahmenfarbton.";";
$rahmenstyle_04 = "border-top:".$seitenrahmen[0]."px solid ".$rahmenfarbton.";";
$rahmenstyle_04.= "border-right:".$seitenrahmen[1]."px solid ".$rahmenfarbton.";";
$rahmenstyle_04.= "border-left:".$seitenrahmen[3]."px solid ".$rahmenfarbton.";";
$rahmenstyle_04.= "border-bottom:".$seitenrahmen[2]."px solid ".$rahmenfarbton.";";
}
if ( $menu_position == "outside" ) {
$rahmenstyle_01 = "";
$rahmenstyle_01 = "border-bottom:".$seitenrahmen[0]."px solid ".$rahmenfarbton.";";
//$rahmenstyle_01.= "border-left:".$seitenrahmen[3]."px solid ".$rahmenfarbton.";";
//$rahmenstyle_01.= "border-top:".$seitenrahmen[0]."px solid ".$rahmenfarbton.";";
}
// Symbolleiste vervollständigen
//if ( $menu_style != "v_v" and $symbol_v_position == "bottom" ) { $rahmenstyle_symbol = $rahmenstyle_02; }
if ( $symbol_leiste ) {
$symbol_leiste = "".$symbol_leiste." |
";
}
$back_image = explode(",",$back_image);
if( $back_image[0] and file_exists("logos/".$back_image[0]) and !$back_image[5] ) {
if ( $back_image[1] ) { $repeat_x = "repeat-x"; }
if ( $back_image[2] ) { $repeat_y = "repeat-y"; }
if ( !$repeat_x and !$repeat_y ) { $no_repeat = "no-repeat"; }
if ( $back_image[3] ) { $pos_x = $back_image[3]; } else { $pos_x = "left"; }
if ( $back_image[4] ) { $pos_y = $back_image[4]; } else { $pos_y = "top"; }
$back_image = "background-image:url(logos/".$back_image[0].");background-repeat:$repeat_x $repeat_y $no_repeat;background-position:$pos_y $pos_x;";
$logo_background_color = "";
} else {
if( $back_image[0] and file_exists("logos/".$back_image[0]) ) {
if ( $back_image[1] ) { $repeat_x = "repeat-x"; }
if ( $back_image[2] ) { $repeat_y = "repeat-y"; }
if ( !$repeat_x and !$repeat_y ) { $no_repeat = "no-repeat"; }
if ( $back_image[3] ) { $pos_x = $back_image[3]; } else { $pos_x = "left"; }
if ( $back_image[4] ) { $pos_y = $back_image[4]; } else { $pos_y = "top"; }
$back_image_abs = "background-image:url(logos/".$back_image[0].");background-repeat:$repeat_x $repeat_y $no_repeat;background-position:$pos_y $pos_x;";
}
$back_image = "";
}
$temp_hintergrundfarbe = $hintergrundfarbe;
if ( (file_exists("objekte/verlauf.gif") and $verlauf) ) {
if ( file_exists("objekte/verlauf.gif") and $verlauf ) {
$verlauf = "background-image:url(objekte/verlauf.gif);background-repeat:repeat-x;background-position:top left;";
}
$hintergrundfarbe = "";
}
$background = "bgcolor='$hintergrundfarbe'";
if ($menu_style == "v_v") {
$background = "";
$rahmenstyle_04.= ";background-color:$hintergrundfarbe;";
}
if ($menu_style == "reiter" or $menu_style == "v_h" or $menu_style == "h_v" ) {
$background = "";
$rahmenstyle_02.= ";background-color:$hintergrundfarbe;";
}
//if ( $gesamtausrichtung == "center" ) { $gesamtausrichtung = ""; }
//echo $content_head;
//echo $_SESSION[$_SESSION['http_host_extended']]['menu_aktiv']['ID'];
//echo ""; print_r($galerie); echo "
";
if ( $head_content and $action != "edit" ) {
$head_content = explode("//",$head_content);
$head_id = $head_content[0];
$head_size = $head_content[1];
$head_margin = $head_content[2];
$head_trenner = $head_content[3];
$head_position = $head_content[4];
$head_hide = $head_content[5];
$head_subtitle = $head_content[6];
if ( !$head_hide or !$bildfile ) {
$head_margin = explode(",",$head_margin);
$head_margin_top = $head_margin[0]."px";
$head_margin_right = $head_margin[1]."px";
$head_margin_bottom = $head_margin[2]."px";
$head_margin_left = $head_margin[3]."px";
if (!$bilder) {
$bilder = reader("bilddatenbank");// ---- werden jetzt in menu.php gelesen
}
$fotograf = $bilder['id_daten'][$head_id]['FOTOGRAF'];
$head_content = $bilder['id_daten'][$head_id]['ID']."__".$bilder['id_daten'][$head_id]['NAME'];
$suffix = substr($head_content,strrpos($head_content,".")+1);
$head_bild = resize_picture($head_content,"bilder/",$picture_quality,$head_size,"y",$suffix,$wasserzeichen,$fotograf);
if ( $head_position != "right" and $head_position != "left" ) {
$rowspan_v_v = "rowspan='2'";
$head_size_all = getimagesize("bilder/".$head_content);
$head_height = round(( $head_size * $head_size_all[1] / $head_size_all[0] ) + $head_margin_top + $head_margin_bottom);
}
$head_content = "";
if ( trim($head_trenner) ) {
$head_content.= " |
";
}
if ( $head_position != "right" and $head_position != "left" ) {
$rowspan_v_v = "rowspan='2'";
}
if ( $head_position != "right" and $head_position != "left" ) {
$head_content.= "";
}
//$head_content.= "";
$head_content.= " | ";
//$rahmenstyle_04 = substr($rahmenstyle_04,strpos($rahmenstyle_04,";"));
$rahmenstyle_02.= "border-right:0px";
$head_content.= "";
$head_content.= " ";
$subtitle = nl2br($bilder['id_daten'][$head_id]['BILDUNTERSCHRIFT']);
if ( $head_subtitle and $subtitle ) {
$head_content.= " ".$subtitle." ";
}
$head_content.= " ";
$head_content.= $menu_head;
$head_content.= " | ";
if ( $head_position != "right" and $head_position != "left" ) {
$head_content.= "
";
}
} else {
$head_content = "";
}
} else {
$head_content = "";
}
$mindesthoehe[10] = "100%";
if ( !$seitenrand and $menu_style == "v_v" ) {
$mindesthoehe[0] = "100%";
} else {
if ( substr_count($mindesthoehe[0],"%") == 0 ) {
$mindesthoehe[0] = $mindesthoehe[0]-1-$head_height;
if ( $mindesthoehe[0] < 0 ) { $mindesthoehe[0] = 0; }
$mindesthoehe[10] = $mindesthoehe[0]-1;
}
}
if ( $_SESSION[$_SESSION['http_host_extended']]['menu_aktiv']['MODUL'] == "login" ) {
$login_focus = "onLoad='setLoginFocus()'";
}
?>