home *** CD-ROM | disk | FTP | other *** search
- <?
- // Configuration Area /\ Area De Configuraτπo \\
-
- $opcao['ordenar'] = 1;
- $opcao['estilo'] = 1;
- $opcao['showmode'] = 1;
-
- $opcao['data'] = 1;
- $opcao['data-formato'] = "H:i:s d.M Y";
- $opcao['tamanho'] = 1;
- $opcao['itens'] = 1;
- $opcao['tipo'] = 1;
- $opcao['icon-path']="/icons/";
-
- $opcao['icon-width'] = "50";
- $opcao['icon-height'] = "50";
- $opcao['icon-small-width'] = "15";
- $opcao['icon-small-height'] = "15";
-
- $opcao['lang'] = "en";
- // $opcao['lang'] = "pt_PT";
-
- $opcao['texto-mostrar'] = 1;
-
- $opcao['max-size'] = 23;
-
- $aliases=array(
- '', ''
- );
-
- // End of Configuration Area /\ Fim da Area De Configuraτπo \\
-
-
-
-
-
- if($opcao['lang']=="pt_PT") {
- $opcao['titulo'] = "Listagem Da Directoria: $directoria";
- $opcao['form-ordenar'] = "Ordenar Por:";
- $opcao['form-icons'] = "Estilo:";
- $opcao['form-show'] = "Vista:";
- $opcao['form-submeter'] = "ok";
- $opcao['texto'] = "<i>Directoria:</i> $directoria";
- $opcao['icon-file'] = "Ficheiro";
- $opcao['icon-dir'] = "Directoria";
- $opcao['lang-nome'] = "Nome";
- $opcao['lang-tamanho'] = "Tamanho";
- $opcao['lang-itens'] = "Itens";
- $opcao['lang-modificado'] = "Modificado";
- $opcao['lang-tipo'] = "Tipo";
-
- $estilos[0] = "AquaFusion";
- $estilos[1] = "Crystal";
- $estilos[2] = "Konqueror";
- $estilos[3] = "Simples";
- $estilos[4] = "Windows";
-
- $ordenars[0] = "Nome";
- $ordenars[1] = "Data";
- $ordenars[2] = "Tamanho";
-
- $vistas[0] = "Icons";
- $vistas[1] = "Detalhes";
- }
- else if($opcao['lang']=="en") {
- $opcao['titulo'] = "Listing Directory: $directoria";
- $opcao['form-ordenar'] = "Order By:";
- $opcao['form-icons'] = "Theme:";
- $opcao['form-show'] = "View:";
- $opcao['form-submeter'] = "ok";
- $opcao['texto'] = "<i>Directory:</i> $directoria";
- $opcao['icon-file'] = "File";
- $opcao['icon-dir'] = "Directory";
- $opcao['lang-nome'] = "Name";
- $opcao['lang-tamanho'] = "Size";
- $opcao['lang-itens'] = "Items";
- $opcao['lang-modificado'] = "Modified";
- $opcao['lang-tipo'] = "Type";
-
- $estilos[0] = "AquaFusion";
- $estilos[1] = "Crystal";
- $estilos[2] = "Konqueror";
- $estilos[3] = "Simple";
- $estilos[4] = "Windows";
-
- $ordenars[0] = "Name";
- $ordenars[1] = "Date";
- $ordenars[2] = "Size";
-
- $vistas[0] = "Icons";
- $vistas[1] = "Details";
-
- }
-
- function put_style() {
- echo "a {
- color: #57a;
- text-decoration: none;
- background-color: transparent;
- }
- a:visited {
- color: #57a;
- background-color: transparent;
- }
- .dirview-item {
- font-family: arial,sans-serif;
- float: left;
- width: 150px;
- text-align: center;
- font-size: x-small;
- padding-top: 0.5em;
- }
- .dirview-info {
- color: #999;
- background-color: transparent;
- }
- .dirview-date {
- color: #999;
- background-color: transparent;
- }
- ";
- }
-
- function put_form() {
- global $estilos, $estilo, $ordenar, $ordenars, $opcao, $vista, $vistas;
- if(($opcao['ordenar'] + $opcao['estilo'] + $opcao['showmode'])!=0) {
- echo "<div align=\"right\"><form action=\"http://" . $_SERVER["HTTP_HOST"] . $_SERVER["REQUEST_URI"] . "\">\n";
- if($opcao['ordenar']==1) {
- echo" <label for=\"ordenar\">".$opcao['form-ordenar']."</label>
- <select id=\"ordenar\" name=\"ordenar\">\n";
- echo "<option value=\"$ordenar\"> * $ordenars[$ordenar]</option>\n";
- $i=0;
- foreach ($ordenars as $var) {
- if ($i != $ordenar) { echo "<option value=\"$i\">$var</option>\n"; }
- $i++;
- }
- echo "</select> ";
- }
-
- if($opcao['estilo']==1) {
- echo "<label for=\"estilo\">".$opcao['form-icons']."</label>
- <select id=\"estilo\" name=\"estilo\">\n";
- echo "<option value=\"$estilo\"> * $estilos[$estilo]</option>\n";
- $i=0;
- foreach ($estilos as $var) {
- if ($i != $estilo) { echo "<option value=\"$i\">$var</option>\n"; }
- $i++;
- }
- echo "</select> ";
- }
-
- if($opcao['showmode']==1) {
- echo "<label for=\"showmode\">".$opcao['form-show']."</label>
- <select id=\"showmode\" name=\"showmode\">\n";
- echo "<option value=\"$vista\"> * $vistas[$vista]</option>\n";
- $i=0;
- foreach ($vistas as $var) {
- if ($i != $vista) { echo "<option value=\"$i\">$var</option>\n"; }
- $i++;
- }
- echo "</select> ";
- }
-
- if(($opcao['ordenar'] + $opcao['estilo'] + $opcao['showmode'])!=0) { echo " <input type=\"submit\" value=\"".$opcao['form-submeter']."\" /></form></div>"; }
- }
- }
- if (!$ordenar) { $ordenar = $_COOKIE["devile-list_ordenar"]; }
- if ( ! in_array($ordenar, array(0, 1, 2))) { $ordenar = 0; }
- if ( $ordenar == $null ) { $ordenar = 0; }
- if ( ! is_numeric($ordenar) ) { $ordenar = 0; }
-
- if (!$estilo) { $estilo = $_COOKIE["devile-list_style"]; }
- if ( ! in_array($estilo, array(0, 1, 2, 3, 4))) { $estilo = 3; }
- if ( $estilo == $null ) { $estilo = 3; }
- if ( ! is_numeric($estilo) ) { $estilo = 3; }
-
- if (!$vista) { $vista = $_COOKIE["devile-list_vista"]; }
- if ( ! in_array($vista, array(0, 1))) { $vista = 0; }
- if ( $vista == $null ) { $vista = 0; }
- if ( ! is_numeric($vista) ) { $vista = 0; }
-
- switch($ordenar) {
- case 0: $ord=0; break;
- case 1: $ord=1; break;
- case 2: $ord=2; break;
- Default: $ord=0; break;
- }
-
-
- // Definir Extenτ⌡es \\
-
- $imagens = array(".jpg", ".gif", ".png", ".jpeg", ".bmp");
- $comprimido = array(".bz2", ".zip", ".gz", ".tar", ".rar", ".ace", ".tgz");
- $midi = array(".mid", ".midi");
- $html = array(".htm", ".html");
- $executavel = array(".exe");
- $ttf = array(".ttf");
- $php = array(".php", ".phps", ".php3", ".php4");
- $texto = array(".txt", ".doc");
- $video = array(".avi", ".mpg", ".mpeg", ".ram", ".asf", ".wmv", ".mov");
- $musica = array(".mp3", ".wav", ".wma", ".ogg");
- $js = array(".js");
-
- switch($estilo) {
- case 3:
-
- // . SIMPLES
-
- $exts = array("");
- $unknown_file = $opcao['icon-path']."indexer/simples/simples-file.png";
- $directoria_file = $opcao['icon-path']."indexer/simples/simples-dir.png";
-
- $small_unknown_file = $opcao['icon-path']."indexer/simples/simples_small-file.png";
- $small_directoria_file = $opcao['icon-path']."indexer/simples/simples_small-dir.png";
-
- break;
-
-
- case 1:
-
- // . Crystal
-
- $exts = array("js", "musica", "video", "imagens", "comprimido", "midi", "html", "executavel", "php", "texto", "ttf");
-
- $imagens_file = $opcao['icon-path']."indexer/crystal/crystal-imagem.jpg";
- $comprimido_file = $opcao['icon-path']."indexer/crystal/crystal-comprimido.jpg";
- $midi_file = $opcao['icon-path']."indexer/crystal/crystal-midi.jpg";
- $musica_file = $opcao['icon-path']."indexer/crystal/crystal-musica.jpg";
- $html_file = $opcao['icon-path']."indexer/crystal/crystal-html.jpg";
- $executavel_file = $opcao['icon-path']."indexer/crystal/crystal-executavel.jpg";
- $ttf_file = $opcao['icon-path']."indexer/crystal/crystal-ttf.jpg";
- $texto_file = $opcao['icon-path']."indexer/crystal/crystal-texto.jpg";
- $js_file = $opcao['icon-path']."indexer/crystal/crystal-js.jpg";
- $php_file = $opcao['icon-path']."indexer/crystal/crystal-html.jpg";
- $video_file = $opcao['icon-path']."indexer/crystal/crystal-filme.jpg";
- $directoria_file = $opcao['icon-path']."indexer/crystal/crystal-directoria.jpg";
- $unknown_file = $opcao['icon-path']."indexer/crystal/crystal-unknown.jpg";
-
- $small_imagens_file = $opcao['icon-path']."indexer/crystal/crystal_small-imagem.jpg";
- $small_comprimido_file = $opcao['icon-path']."indexer/crystal/crystal_small-comprimido.jpg";
- $small_midi_file = $opcao['icon-path']."indexer/crystal/crystal_small-midi.jpg";
- $small_musica_file = $opcao['icon-path']."indexer/crystal/crystal_small-musica.jpg";
- $small_html_file = $opcao['icon-path']."indexer/crystal/crystal_small-html.jpg";
- $small_executavel_file = $opcao['icon-path']."indexer/crystal/crystal_small-executavel.jpg";
- $small_ttf_file = $opcao['icon-path']."indexer/crystal/crystal_small-ttf.jpg";
- $small_texto_file = $opcao['icon-path']."indexer/crystal/crystal_small-texto.jpg";
- $small_js_file = $opcao['icon-path']."indexer/crystal/crystal_small-js.jpg";
- $small_php_file = $opcao['icon-path']."indexer/crystal/crystal_small-html.jpg";
- $small_video_file = $opcao['icon-path']."indexer/crystal/crystal_small-filme.jpg";
- $small_directoria_file = $opcao['icon-path']."indexer/crystal/crystal_small-directoria.jpg";
- $small_unknown_file = $opcao['icon-path']."indexer/crystal/crystal_small-unknown.jpg";
-
- break;
-
- case 0:
-
- // . Aqua Fusion
-
- $exts = array("ttf", "js", "musica", "video", "imagens", "comprimido", "midi", "html", "executavel", "php", "texto");
-
- $imagens_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-image.png";
- $comprimido_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-tgz.png";
- $midi_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-midi.png";
- $musica_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-sound.png";
- $html_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-html.png";
- $executavel_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-binary.png";
- $ttf_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-font_truetype.png";
- $php_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-source.png";
- $texto_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-txt.png";
- $js_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-source.png";
- $video_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-video.png";
- $ttf_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-font_truetype.png";
- $directoria_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-folder.png";
- $unknown_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion-unknown.png";
-
- $small_imagens_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-image.png";
- $small_comprimido_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-tgz.png";
- $small_midi_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-midi.png";
- $small_musica_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-sound.png";
- $small_html_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-html.png";
- $small_executavel_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-binary.png";
- $small_ttf_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-font_truetype.png";
- $small_php_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-source.png";
- $small_texto_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-txt.png";
- $small_js_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-source.png";
- $small_video_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-video.png";
- $small_ttf_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-font_truetype.png";
- $small_directoria_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-folder.png";
- $small_unknown_file = $opcao['icon-path']."indexer/AquaFusion/AquaFusion_small-unknown.png";
-
-
- break;
-
-
-
- case 2:
-
- // . Konqueror
-
- $exts = array("imagens", "comprimido", "midi", "html", "executavel", "ttf", "php", "texto");
-
- $imagens_file = $opcao['icon-path']."indexer/konqueror/konqueror-imagem.png";
- $comprimido_file = $opcao['icon-path']."indexer/konqueror/konqueror-comprimido.png";
- $midi_file = $opcao['icon-path']."indexer/konqueror/konqueror-midi.png";
- $html_file = $opcao['icon-path']."indexer/konqueror/konqueror-html.png";
- $executavel_file = $opcao['icon-path']."indexer/konqueror/konqueror-executavel.png";
- $ttf_file = $opcao['icon-path']."indexer/konqueror/konqueror-ttf.png";
- $php_file = $opcao['icon-path']."indexer/konqueror/konqueror-texto.png";
- $texto_file = $opcao['icon-path']."indexer/konqueror/konqueror-texto.png";
- $directoria_file = $opcao['icon-path']."indexer/konqueror/konqueror-directoria.png";
- $unknown_file = $opcao['icon-path']."indexer/konqueror/konqueror-texto.png";
-
- $small_imagens_file = $opcao['icon-path']."indexer/konqueror/konqueror_small-imagem.png";
- $small_comprimido_file = $opcao['icon-path']."indexer/konqueror/konqueror_small-comprimido.png";
- $small_midi_file = $opcao['icon-path']."indexer/konqueror/konqueror_small-midi.png";
- $small_html_file = $opcao['icon-path']."indexer/konqueror/konqueror_small-html.png";
- $small_executavel_file = $opcao['icon-path']."indexer/konqueror/konqueror_small-executavel.png";
- $small_ttf_file = $opcao['icon-path']."indexer/konqueror/konqueror_small-ttf.png";
- $small_php_file = $opcao['icon-path']."indexer/konqueror/konqueror_small-texto.png";
- $small_texto_file = $opcao['icon-path']."indexer/konqueror/konqueror_small-texto.png";
- $small_directoria_file = $opcao['icon-path']."indexer/konqueror/konqueror_small-directoria.png";
- $small_unknown_file = $opcao['icon-path']."indexer/konqueror/konqueror_small-texto.png";
-
-
- break;
-
- case 4:
-
- // . Windows
-
- $exts = array("js", "musica", "video", "imagens", "comprimido", "midi", "html", "executavel", "php", "texto");
-
- $imagens_file = $opcao['icon-path']."indexer/windows/windows-imagem.png";
- $comprimido_file = $opcao['icon-path']."indexer/windows/windows-comprimido.png";
- $midi_file = $opcao['icon-path']."indexer/windows/windows-musica.png";
- $musica_file = $opcao['icon-path']."indexer/windows/windows-musica.png";
- $html_file = $opcao['icon-path']."indexer/windows/windows-html.png";
- $executavel_file = $opcao['icon-path']."indexer/windows/windows-executavel.png";
- $ttf_file = $opcao['icon-path']."indexer/windows/windows-ttf.png";
- $texto_file = $opcao['icon-path']."indexer/windows/windows-texto.png";
- $js_file = $opcao['icon-path']."indexer/windows/windows-js.png";
- $php_file = $opcao['icon-path']."indexer/windows/windows-html.png";
- $video_file = $opcao['icon-path']."indexer/windows/windows-filme.png";
- $directoria_file = $opcao['icon-path']."indexer/windows/windows-directoria.png";
- $unknown_file = $opcao['icon-path']."indexer/windows/windows-unknown.png";
-
- $small_imagens_file = $opcao['icon-path']."indexer/windows/windows_small-imagem.png";
- $small_comprimido_file = $opcao['icon-path']."indexer/windows/windows_small-comprimido.png";
- $small_midi_file = $opcao['icon-path']."indexer/windows/windows_small-musica.png";
- $small_musica_file = $opcao['icon-path']."indexer/windows/windows_small-musica.png";
- $small_html_file = $opcao['icon-path']."indexer/windows/windows_small-html.png";
- $small_executavel_file = $opcao['icon-path']."indexer/windows/windows_small-executavel.png";
- $small_ttf_file = $opcao['icon-path']."indexer/windows/windows_small-ttf.png";
- $small_texto_file = $opcao['icon-path']."indexer/windows/windows_small-texto.png";
- $small_js_file = $opcao['icon-path']."indexer/windows/windows_small-js.png";
- $small_php_file = $opcao['icon-path']."indexer/windows/windows_small-html.png";
- $small_video_file = $opcao['icon-path']."indexer/windows/windows_small-filme.png";
- $small_directoria_file = $opcao['icon-path']."indexer/windows/windows_small-directoria.png";
- $small_unknown_file = $opcao['icon-path']."indexer/windows/windows_small-unknown.png";
-
- break;
-
- }
- $i=count($aliases);;
- $z=0;
- for($f=0;$f<$i;$f++) {
- $user_alias[$z]=$aliases[$f];
- $size_alias[$z]=strlen($aliases[$f]);
- $f++;
- $disk_alias[$z]=$aliases[$f];
- $z++;
- }
- array_multisort($size_alias,SORT_DESC,SORT_NUMERIC,$user_alias,$disk_alias);
-
- ?>
-