Ver Mensaje Individual
  #2 (permalink)  
Antiguo 10/10/2006, 07:59
Cluster
O_O
 
Fecha de Ingreso: enero-2002
Ubicación: Santiago - Chile
Mensajes: 34.417
Antigüedad: 22 años, 3 meses
Puntos: 129
Usa session_write_close(); despues de tu include "seguridad.php" donde supongo que harás uso de alguna variable de sesión ...

El comentario viene de otro comentario de php.net:

Cita:
bkatz at usefulengineering dot com
16-Jul-2005 11:05
session_write_close() worked as a lifesaver for me when automatically uploading files to a user (forcing a download instead of a link). If files are large, and since session_start() does not allow another page using session_start() to proceed until it's done, i was not able to upload more than one file at a time. By using session_write_close() before beginning the file upload, my users can now download as many big files as they like, at the same time. Example:

Código PHP:
<?
session_start
();
/* Do session stuff here; security; logging; etc. */
session_write_close();
/* NOW write out the requested file. */
header("Content-type: audio/x-mpeg"); /* or whatever type */
header("Content-Disposition: attachment; filename=" $filename); 
header("Content-Length: " $filesize);
header("Content-Transfer-Encoding: binary\n\n");
header("Pragma: no-cache"); 
header("Expires: 0"); 
$file_contents file_get_contents($filepath);    
print(
$file_contents);
?>
Un saludo,
__________________
Por motivos personales ya no puedo estar con Uds. Fue grato haber compartido todos estos años. Igualmente los seguiré leyendo.