| |
|
|
| | при выводе папок я заменяю имена директорий их русскими эквивалентами если они есть, а в вот в этом коде $tip заменяется,$f заменяется,а $f1 нет,не подскажете почему?А без замены все выходит
<?php
$dirr = opendir("./$load/$tip/");
// В цикле выводим его содержимое
while (($f = readdir($dirr)) !== false)
if ($f == "." || $f == ".." || $f == "index.php" || $f == "what.tpl"){continue;}
else {
print " <fieldset class='block2'>
//переводим заголовок
<legend>";if(!@constant($tip))print $tip;else print @constant($tip);print "</legend>";
//переводим имя папки1
print"<a href=\"static.php?load=$load/$tip&tip=$f\"><h3>";if(!@constant($f))print $f;else print @constant($f);print "</h3></a>\n";
//если папка1-папка открываем её
if (is_dir("./$load/$tip/$f/"))
{
$dirr1 = opendir("./$load/$tip/$f/");
// В цикле выводим его содержимое
while (($f1 = readdir($dirr1)) !== false)
if ($f1 == "." || $f1 == ".." || $f1 == "index.php" || $f1 == "what.tpl"){continue;}
else print"
//переводим имя папки1а,папки1б,папки1в... вот здесь не переводит!!!
<a class='vvod' href=\"static.php?load=$load/$tip/$f&tip=$f1\">";if(!@constant($f1))print $f1;else print @constant($f1);print "</a><br/>"; }
print "</fieldset>";
}
closedir($dirr1); closedir($dirr);
}
?>
|
| |
| |
|