Código PHP:
<form name="agregar" method="post" action="agregar.php?recordID=<?php echo $numero;?>&numit=<?php echo $numtotal;?>">
<?php
$insertaritem=mysql_query("SELECT * FROM articul1 order by codigo");
if(!$result1){
die("el query fallo" . mysqlerror($result1));}
//Mostramos los registros
echo '<select name="productos" size="1">';
while ($rowinserta=mysql_fetch_array($insertaritem))
{
echo '<option value="'.$rowinserta["CODIGO"].'">
'.$rowinserta["CODIGO"] . ' - ' . $rowinserta["DESCRIPCION"].'</option>';
$categoria=$row['CATEGORIA'];
$codigo=$rowinserta['CODIGO'];
$obtenerprecio=mysql_query("SELECT * from articul8 where [COLOR="Blue"]'$codigo'[/COLOR]=articul8.idart1 and articul8.tipo='$categoria'", $conexion);
if(!$obtenerprecio){
die("el query fallo" . mysqlerror($obtenerprecio));}
while ($rowprecio=mysql_fetch_array($obtenerprecio)){
$obtprecio=$rowprecio['PRECIO'];
}
}
echo '</select>';
?>
<input type="text" name="cantidadingreso" size="2" />
<input type="hidden" name="categoria" value="<?php echo $categoria;?>" />
<input type="hidden" name="precioobt" value="<?php echo $obtprecio;?> " />
<?php
}
echo '<input type="submit" value="insertar"/>';
?>
</form>
aqui lo que me arroja el print_r:
Array ( [productos] => 0-60 [cantidadingreso] => 5 [categoria] => 1 [precioobt] => 33000.00 )
gracias de antemano