\n"; while(false !== ($file = readdir($contents))){ $docslist[] = $file; } sort($docslist); foreach ($docslist as $file){ if (is_dir("inhalt/src/$folder/$file") && $file != "." && $file != ".." && !in_array($file, $hide) && substr($file,0,1) != "_") { //Namen schönen $filename = substr($file,4); $ersetz_weg = array("_", "-", "uero", "fuer", "uede", "Ae","Oe","Ue","gaer","haeu","oe","sz", "fueh"); $ersetz_hin = array(" ", " ", "üro", "für", "üde", "Ä","Ö","Ü","gär","häu","ö","ß", "füh"); $filename = str_replace($ersetz_weg,$ersetz_hin,$filename); //Namen schönen end $out .= "".$filename."\n"; //if (($file == $content) OR ($file == $sub) OR ($file == $sub2 OR ($file == $sub3))){ scan($folder."/".$file, $root."/".$file); //} $out .= "\n"; } elseif($file != "." && $file != ".." && !in_array($file, $hide) && substr($file,0,1) != "_"){ $out .= "
  • $file
  • \n"; } } closedir($contents); $out .= "\n"; } return $out; } // function end // Navigation erstellen end // function start $out2 = ''; function scan2($folder,$root){ global $hide, $out2, $root; //Nice URL $requestURI = explode('/', $_SERVER['REQUEST_URI']); $scriptName = explode('/',$_SERVER['SCRIPT_NAME']); for($i= 0;$i < sizeof($scriptName);$i++) { if ($requestURI[$i] == $scriptName[$i]) { unset($requestURI[$i]); } } $command = array_values($requestURI); $lang = trim($command[0]); if($lang == "") { $lang = "de"; } $content = trim($command[1]); if($content == "") { $content = "00--Start"; } $sub = trim($command[2]); $sub2 = trim($command[3]); //Nice URL Ende if($contents = opendir("inhalt/src/".$folder)){ $out2 .= "".$filename."\n"; if (($file == $content) OR ($file == $sub) OR ($file == $sub2 OR ($file == $sub3))){ scan2($folder."/".$file, $root."/".$file); } $out2 .= "\n"; } elseif($file != "." && $file != ".." && !in_array($file, $hide) && substr($file,0,1) != "_"){ $out2 .= "
  • $file
  • \n"; } } closedir($contents); $out2 .= "\n"; } return $out2; } // function end // Navigation erstellen end function title($string, $pascalCase = false) { $string = str_replace(array('-', '_'), ' ', $string); $string = ucwords($string); if (!$pascalCase) { return ucfirst($string); } return $string; } $content_title = substr($content,4); if (!empty ($sub)) { $sub_title = substr($sub,3); } if (!empty ($sub2)) { $sub2_title = " : ".substr($sub2,3);} if ($content == "") { $content = "00--Start"; } if ($lang != "de") { $langi = "_".$lang; } //echo $lang."/".$content."/".$sub; ?>