
16/06/2004, 01:35
|
| | Fecha de Ingreso: abril-2004
Mensajes: 21
Antigüedad: 20 años, 10 meses Puntos: 0 | |
Muchas gracias
Ahora con esta parte ya no tengo problemas, sino con la de descarga.php.
El código que utilizo yo es el siguiente, ya que no utilizo la variable url en la tabla: <?php
function descarga()
{
include("lib/conectarse.php");
$link1=conectarse( );
$consul = "select nom, pes from arxiu where id=".$_GET
['id'];
$resul = mysql_query($consul,$link1);
$reg = mysql_fetch_array($resul);
header("Content-Disposition: attachment; filename=".$reg['nom'].";");
header("Content-Type: application/force-download");
header("Content-Length: ".$reg['pes']);
readfile($reg["'../upload/'.nom"]);
exit;
}
?>
Al hacer el link me dice que no se encuentra la pàgina, que puede ser |