~marcelo-escobal/geined/Alianza

« back to all changes in this revision

Viewing changes to download.php

  • Committer: Cualquier Desarrollador
  • Date: 2010-01-29 21:15:22 UTC
  • Revision ID: desarrollo@marte-20100129211522-u97qh9o90mhdap04
Importación inicial

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?php
 
2
include('funciones.php');
 
3
autorizacion(5);
 
4
encabezado("Bajar archivos");
 
5
boton("Volver","alianza.py?accion=sistema");
 
6
if ($handle = opendir('./uploads')) {
 
7
  /* This is the correct way to loop over the directory. */
 
8
    encabezado_tabla(array("Archivo","Accion"));
 
9
  while (false !== ($file = readdir($handle))) {
 
10
        if($file!='.' and $file!='..'){
 
11
            echo '<tr>';
 
12
            echo "<td>$file</td>";
 
13
            echo '<td>';
 
14
            boton("Descargar","./uploads/$file");
 
15
            echo '</td>';
 
16
            echo '</tr>';
 
17
            }
 
18
    }
 
19
  closedir($handle);
 
20
}
 
21
fin_tabla();
 
22
boton("Volver","alianza.py?accion=sistema");
 
23
?>