
26/04/2010, 12:45
|
 | | | Fecha de Ingreso: octubre-2009 Ubicación: palmira
Mensajes: 103
Antigüedad: 15 años, 3 meses Puntos: 0 | |
Respuesta: arreglos en php esto es lo q llevo hecho...puse unos text pero no funcionan..los puse de prueba....como logro que los text que puse en el while almacenen en el arreglo??
<?php
echo '
<form action="index3.php" method="post">
ingrese el numero de veces
<input type="text" name="text" />
<input type="submit" name="submit" value="enviar"/>
</form>';
$veces=$_POST['text'];
$var=0;
while($var < $veces){
echo '
<form action="index.php" method="post"></br>';
echo "ingrese el valor " .$var."";
echo '<input type="text" name="$var[]" /></br>';
$vector=array("5","4","3");
sort($vector);
foreach($vector as $key=>$val){
echo "posicion[" . $key . "] numero= " . $val . "<br>";
}
$var++;
}
?>
<?php
echo '<input type="submit" name="submit" value="almacenar"/>
</form>';
?>
saludos.. |