GetSearchTextData($_POST['search']); } $merkmalset=new merkmalSet('site'); if(isset($_REQUEST['id'])&&$_REQUEST['id']!=""){ $sitedata=$merkmalset->getLinkedidRealDataSet($_REQUEST['id']); if(is_file($sitedata[192]['val'].'.htm')&&$sitedata[192]['val']!=""&&$_REQUEST['control_mode']!=1&&($_SERVER["REQUEST_URI"]=='/'||$_SERVER["REQUEST_URI"]=='/index.php')){ header("HTTP/1.1 301 Moved Permanently"); //header("Location: http://www.".$_SESSION['my_host']."/".$sitedata[192]['val'].".htm"); header("Location: http://".$_SESSION['my_host']."/".$sitedata[192]['val'].".htm"); header("Connection: close"); } } if($filename!=""&&$filename!="index"){ $id=$merkmalset->getLinkedidBySymlink($filename,192); if($id!=false&&$_REQUEST['id']=="")$_REQUEST['id']=$id['linkedid']; } if(isset($_REQUEST['logout'])&&$_REQUEST['logout']==1){ $login=new websiteUser(); $login->Logout(); header("Location: ./index.php"); } if($_REQUEST['id']==""){ $id=$merkmalset->getLinkedidBySymlink(1,40000); if($id!=false&&$_REQUEST['id']=="")$_REQUEST['id']=$id['linkedid']; } $sitedata=$merkmalset->getLinkedidRealDataSet($_REQUEST['id']); /*if($sitedata[2145]['val']!=1 && $WEBSITELOGIN['linkedid']=="" && $control_mode!=1){ $_REQUEST['id']=62; $sitedata=$merkmalset->getLinkedidRealDataSet($_REQUEST['id']); }*/ //$ribbondata=$merkmalset->getRibbonSet('site'); $menu_tree=new Tree($PEAR_dsn,'site','menu','1'); $site_menudata=$menu_tree->getNodeData($_REQUEST['id']); if($sitedata[177]['val']==1){ $temp=$menu_tree->getChildren($site_menudata['id']); reset($temp); $first_child=current($temp); $_REQUEST['id']=$first_child['linkedid']; $sitedata=$merkmalset->getLinkedidRealDataSet($_REQUEST['id']); $menu_tree=new Tree($PEAR_dsn,'site','menu','1'); $site_menudata=$menu_tree->getNodeData($_REQUEST['id']); } if($sitedata[2115]['val']!=""){ $_REQUEST['id']=$sitedata[2115]['val']; $sitedata=$merkmalset->getLinkedidRealDataSet($_REQUEST['id']); $menu_tree=new Tree($PEAR_dsn,'site','menu','1'); $site_menudata=$menu_tree->getNodeData($_REQUEST['id']); } $parentsite_menudata=$menu_tree->getNodeDatabyId($site_menudata['sub']); $parentparentsite_menudata=$menu_tree->getNodeDatabyId($parentsite_menudata['sub']); $smarty = new Smarty(); $smarty->setTemplateDir(SmartyConfiguration::SMARTY_DIR.'/templates'); $smarty->setCompileDir(SmartyConfiguration::SMARTY_DIR.'/templates_c'); $smarty->setCacheDir(SmartyConfiguration::SMARTY_DIR.'/cache'); $smarty->setConfigDir(SmartyConfiguration::SMARTY_DIR.'/configs'); $textclass=new textClass($_REQUEST['id']); $textdata=$textclass->GetAllSiteTextData(); foreach($textdata as $td) $smarty->assign($td[130], $td[132]); $smarty->assign("sitedata", $sitedata,true); //if($sitedata[128]['val']=="")die("no template defined"); if($sitedata[128]['val']=="")$sitedata[128]['val']='text.tpl'; $smarty->assign("rquestvars", $_REQUEST); $smarty->assign("sessionvars", $_SESSION); $smarty->assign("websitelogin", $_SESSION['WEBSITELOGIN']); $smarty->assign("Title", $sitedata[120]['val'],true); $smarty->assign("Name", $sitedata[119]['val'],true); $smarty->assign("Description", $sitedata[121]['val'],true); $smarty->assign("Keywords", $sitedata[122]['val'],true); $smarty->assign("Stylesheet", $sitedata[124]['val'],true); $smarty->assign("ContentLanguage", $sitedata[125]['val'],true); $smarty->assign("Generator", $sitedata[126]['val'],true); $smarty->assign("treenodeid", $_REQUEST['treenodeid'],true); $smarty->assign("id", $_REQUEST['id'],true); $smarty->assign("parentid", $parentsite_menudata['linkedid'],true); $smarty->assign("parentparentid", $parentparentsite_menudata['linkedid'],true); $smarty->assign("control_mode", $_REQUEST['control_mode'],true); $smarty->assign("searchresults", $SearchTextData); $vererbt=Array( Array(250,239), Array(251,240), Array(252,241), Array(253,242), Array(254,125), Array(255,243), Array(256,244), Array(257,246), Array(258,245), Array(259,247) ); foreach($vererbt as $ve){ if($sitedata[$ve[0]]['val']!=""&&$sitedata[$ve[1]]['val']==""){ $tempdata=$merkmalset->getLinkedidRealDataSet($sitedata[$ve[0]]['orig_val']); $sitedata[$ve[1]]['val']=$tempdata[$ve[1]]['val']; } } //$smarty->display($sitedata[128]['val']); $smarty->assign("sitedata", $sitedata,true); $site=$smarty->fetch($sitedata[128]['val'], $cache_id); if($_REQUEST['control_mode']!=1) foreach($merkmalset->getAllSymlinks() as $symlink){ $site = preg_replace('/(index.php\?id='.$symlink[0].')([^0-9])/', "/".$symlink[1].'.htm$2', $site); $site = preg_replace('/(\/\?id='.$symlink[0].')([^0-9])/', "http://".$_SERVER['HTTP_HOST']."/".$symlink[1].'.htm$2', $site); $site = preg_replace('/(\?id='.$symlink[0].')([^0-9])/', "http://".$_SERVER['HTTP_HOST']."/".$symlink[1].'.htm$2', $site); $site = str_replace("http://".$_SERVER['HTTP_HOST']."/".$symlink[1].'.htm&', "http://".$_SERVER['HTTP_HOST']."/".$symlink[1].'.htm?', $site); } echo $site; ?>