Christoph Koschel
Mitglied
Ich habe ihr ein kleine Problem ich habe eine Function geschrieben die einen Verzeichnis baum ausgibt diese function sieht so aus:
Diese PHP Function läuft über ein xmlhttpRequest aber die Ausgabe sieht dann so aus und ich weiß nicht warum
css (
index.html (
js (
sketch.js (
Chat (
Design (
User (
index.php (
index.php~ (
Game.css (
Game.css~ (
Game.php (
Game.php~ (
Bilder (
css (
icons (
index.html (
javascript (
musik (
musik.txt (
setting.js (
Terminal-codes.ods (
css (
index.html (
javascript (
update.txt (
Allinfo (
Design (
Global (
User (
backP1.jpg (
backP2.jpg (
backP3.jpg (
backP4.jpg (
index.php (
index.php~ (
passwort.txt (
index.php (
index.php~ (
passwort.txt (
BuildGame (DIRECTORY)
Dom_Fake (DIRECTORY)
Forum (DIRECTORY)
Game (DIRECTORY)
SystemApp (DIRECTORY)
Terminal (DIRECTORY)
Update-App-Data (DIRECTORY)
cgi-bin (DIRECTORY)
chat (DIRECTORY)
hand (DIRECTORY)
schullProject (DIRECTORY)
test.html (FILE)
PHP:
function SHOW($p) {
if (!is_dir($p)) { return; }
$ausgabe = "<ul>";
$inhalt = scandir($p);
foreach ($inhalt as $ele) {
if ($ele == "." or $ele == "..") {
continue;
}
$ausgabe .= "<li>".$ele." (";
if (is_dir($p.$ele)) {
$ausgabe .= "DIRECTORY)";
$ausgabe .= SHOW($p.$ele);
}
if (is_file($p.$ele)) {
$ausgabe .= "FILE)";
}
$ausgabe .= "</li>";
}
$ausgabe .= "</ul>";
echo $ausgabe;
}
Diese PHP Function läuft über ein xmlhttpRequest aber die Ausgabe sieht dann so aus und ich weiß nicht warum
css (
index.html (
js (
sketch.js (
Chat (
Design (
User (
index.php (
index.php~ (
Game.css (
Game.css~ (
Game.php (
Game.php~ (
Bilder (
css (
icons (
index.html (
javascript (
musik (
musik.txt (
setting.js (
Terminal-codes.ods (
css (
index.html (
javascript (
update.txt (
Allinfo (
Design (
Global (
User (
backP1.jpg (
backP2.jpg (
backP3.jpg (
backP4.jpg (
index.php (
index.php~ (
passwort.txt (
index.php (
index.php~ (
passwort.txt (
BuildGame (DIRECTORY)
Dom_Fake (DIRECTORY)
Forum (DIRECTORY)
Game (DIRECTORY)
SystemApp (DIRECTORY)
Terminal (DIRECTORY)
Update-App-Data (DIRECTORY)
cgi-bin (DIRECTORY)
chat (DIRECTORY)
hand (DIRECTORY)
schullProject (DIRECTORY)
test.html (FILE)