setlocale (LC_ALL, 'de_DE@euro', 'de_DE', 'de', 'ge'); /* framework2 master file php base matrix html file server php version 4 apache with mod rewrite mysql database session managment global vars: $act - global actions selector $file - current file $level - the level of the file, needed for templates $level_str - the level in a relative string $page_Content - active page content not evaluated $page_Template_File - page template to use for output building $page_HeadExtra - inset into the head section $page_xxxx - page specific settings for templates $s_xxxx - reserved for session vars, application based */ /* config */ require('inc/config'); require_once('_mainconfig.php'); /* options */ require('inc/options'); /* global page init */ //$page_TitlePre = "HausTierSuche.at - Private Tierschutzinitiative"; //$page_Title= $page_Title; $page_Description = "HausTierSuche.at ist eine private Tierschutzinitiative. Sie suchen ein Haustier? Dann sind Sie bei uns goldrichtig."; $page_Keywords = "Aufzucht, Betreuung, finden, Geschichten, Grosssenzersdorf, Hund, Hundeabrichtung, Hundesitter, Impfung, Katze, Katzenbabies, katzenverträglich, kleinwüchsig, Mischling, suchen, Tiere, Tierschutzgesetz, Urlaubsbetreuung, verträglich, Welpen"; $page_Robots = "index,follow,archive"; $page_HeadExtra = ""; $page_Template_File='html.haustier'; // default template /* gloabal php settings */ if ($config['os']=='win') { ini_set('include_path','.;'.$config['pathroot'].'inc/'); } else { ini_set('include_path','.:'.$config['pathroot'].'inc/'); } $flg_phpini_include_path_ext = true; //extend to current dir ? if ($config['debug']!=0) error_reporting(E_ALL); /* init */ require('inc/class.framework2.php'); /* init framework */ if(!isset($file)) $file='index.html'; // $_SERVER["REQUEST_URI"] $fileoverride = false; if ($file=='error404.html') { $file = substr($_SERVER['REQUEST_URI'],1); //file override to 404 $fileoverride = 404; } elseif ($file=='error403.html') { $file = substr($_SERVER['REQUEST_URI'],1); //file override to 403 $fileoverride = 403; } elseif ($file=='error401.html') { $file = substr($_SERVER['REQUEST_URI'],1); //file override to 401 $fileoverride = 401; } $Framework = new Framework; $Framework->Init_LevelAndFile(); if(!strlen($file_name)) $file .= 'index.html'; $fileinclude = $file; if ($fileoverride) { if ($fileoverride==404) $fileinclude = 'template/html.404'; if ($fileoverride==403) $fileinclude = 'template/html.403'; if ($fileoverride==401) $fileinclude = 'template/html.401'; } /* extend include config */ if ($flg_phpini_include_path_ext) { $ts = ($config['os']=='win')?';':':'; $t = ini_get('include_path'); ini_set('include_path',$t.$ts.$config['pathroot'].$file_path); } /* database (global connect + select) */ if ($dblink = @mysql_connect($config['db']['server'],$config['db']['user'],$config['db']['pass'])) { $dblink = (@mysql_select_db($config['db']['db'],$dblink))?$dblink:false; mysql_query("SET NAMES 'utf8'"); } /* session config */ $flg_usesession = false; if ($flg_usesession) { $s_sessname = 'htsid'; session_name($s_sessname); ini_set('session.use_cookies',1); ini_set('session.use_trans_sid',1); // ini_set('session.use_only_cookies',1); // ini_set('session.save_path',$config['pathroot'].'temp/session'); // ini_set('session.cookie_lifetime',0); // ini_set('session.gc_maxlifetime',3600); //seconds - garbage collector // session.cookie_domain header('P3P: CP="NOI ADM DEV PSAi COM NAV OUR OTRo STP IND DEM"'); } /* session start */ if ($flg_usesession) { session_start(); $_SESSION['new'] = false; if (!isset($_SESSION['bean'])) { $_SESSION['bean'] = 0; $_SESSION['new'] = true; } } /* content selector */ $page_Browseable = true; switch ($file_extension) { case 'pdf': case 'swf': $page_Browseable = false; break; } // phpinfo(); /* global page actions */ if (isset($act)) { } /* find reader component, read and fill $page_Content */ $page_Content = ''; $page_Content_Error = '
Die angeforderte Datei konnte nicht gefunden werden (2).'; /* parameter prüfen */ for ($i = 0; $i < 5; $i++) { $t = 'p'.$i; $$t = isset($_GET[$t]) ? $_GET[$t] : 0; if ($i > 0) { $$t = intval($$t); } } /* find active content and include */ if ($file != $fileinclude) { $file = $fileinclude; } /* entscheide, welche inhalte ausgeführt werden sollen */ switch($p1) { case 0: $file = 'index.html'; break; case 1: $file = 'db.html'; break; case 2: $file = 'stat.html'; break; case 3: $file = 'inserat.html'; break; case 4: $file = 'suche.html'; break; case 5: $file = 'statistik.html'; break; case 6: $file = 'impressum.html'; break; case 7: $file = 'sitting.html'; break; case 8: $file = 'tagebuch.html'; break; case 9: $file = 'unvergessen.html'; break; case 10: $file = 'happyend.html'; break; case 11: $file = 'sos.html'; break; case 12: $file = 'petitionen.html'; break; default: $file = 'template/html.404'; break; } if (is_file($file) === false) { $file = 'template/html.404'; } ob_start(); include($file); $page_Content = ob_get_contents(); ob_end_clean(); if($config['debug']&2) { ob_start(); ?>