Ver Mensaje Individual
  #13 (permalink)  
Antiguo 17/04/2007, 10:11
EDWINSANCHEZ
 
Fecha de Ingreso: octubre-2006
Mensajes: 79
Antigüedad: 17 años, 6 meses
Puntos: 0
Re: Manejo De Arrays De Cajas De Texto Con Hiperenlaces

PERDON EN ESTE CODIGO, QUE ES IGUAL A QUE ME BRINDO GERSON?..


<script>
function obt_val(nro){
alert("Valor de " + document.getElementById('txtdescArticulo['+ nro +']').value);
}
</script>
<form name="opt" method="post" action="#">
<table border="2" align="center" bordercolor="#ECE9D8">
<tr>
<th>Artículo</th>
<th>Descripción</th>
<th>Centro de Costos</th>
<th>Cantidad</th>
<th>Precio</th>
<th>Impuesto</th>
<th>Importe</th>
<th>Total</th>
</tr>
<?php
$txtNroProductos = 5;
for ($i=0;$i<$txtNroProductos;$i++)
{?>
<tr>
<td height="22" width="20" bordercolordark="#454560"><input type="text" size="10" name="txtidArticulo[]">
</td>
<td height="22"><input type="text" name="txtdescArticulo[]" id="txtdescArticulo[<?php echo $i?>]"><a href="javascript: obt_val(<?php echo $i?>)">Ayuda</a></td>

<td height="22" width="20"><input type="text" size="10" name="txtvccArticulo[]"></td>
<td height="22" width="20"><input type="text" size="10" name="txtcantArticulo[]"></td>
<td height="22" width="20"><input type="text" size="10" name="txtprecioArticulo[]"></td>
<td height="22" width="20"><input type="text" size="10" name="txtimpuestoArticulo[]"></td>
<td height="22" width="20"><input type="text" size="10" name="txtimporteArticulo[]"></td>
<td height="22" width="20"><input type="text" size="10" name="txttotalArticulo[]"></td>
</tr>
<?php
}
?>
</table >
</form>