Ver Mensaje Individual
  #4 (permalink)  
Antiguo 27/02/2006, 08:26
Cluster
O_O
 
Fecha de Ingreso: enero-2002
Ubicación: Santiago - Chile
Mensajes: 34.417
Antigüedad: 22 años, 3 meses
Puntos: 129
Y has comprobado que tiene $key y $name en tu bucle:

foreach ($_FILES['archivos']['name'] as $key => $name){
}

?¡?

Según tu caso en $name tendrías mensajes de error concretos ..

Fijate en este ejemplo:
Cita:
Envío de multiples ficheros
Bob Doe
09-Aug-2005 12:17
Here is a the simple test form I needed, pieced togther from 2 or 3 posts in the documentation elsewhere.

Código PHP:
<html>
<head>
<title>HTML Form for uploading image to server</title>
</head>
<body>
<form action="" method="post" enctype="multipart/form-data">
<p>Pictures:
<input type="file" name="pictures[]" />
<input type="file" name="pictures[]" />
<input type="file" name="pictures[]" />
<input type="submit" value="Send" />
</p>
</form>
<?php
//places files into same dir as form resides
foreach ($_FILES["pictures"]["error"] as $key => $error) {
   if (
$error == UPLOAD_ERR_OK) {
       echo
"$error_codes[$error]";
       
move_uploaded_file(
         
$_FILES["pictures"]["tmp_name"][$key], 
         
$_FILES["pictures"]["name"][$key
       ) or die(
"Problems with upload");
   }
}
?>
</body>
</html>
(ahí se "mueve" la imagen .. en tu caso la "lees" de su ubicación temporal para llevartelo a un campo de tu BBDD, el proceso es el mismo en el bucle dato junto con tus otras validaciones si las requieres)

http://www.php.net/manual/es/feature...d.multiple.php

Un saludo,