Foros del Web » Programando para Internet » PHP »

Mostrar datos en textbox

Estas en el tema de Mostrar datos en textbox en el foro de PHP en Foros del Web. Tengo un problema de que no me ve ningun registro. antes lo usaba asi echo "<input type =\"hidden\" name =\"ar_anio[".$i."]\" value=\"".$ar_anio[$i]."\">"; y ningun problema, ahora ...
  #1 (permalink)  
Antiguo 05/02/2008, 06:18
Avatar de hulray  
Fecha de Ingreso: septiembre-2006
Mensajes: 630
Antigüedad: 17 años, 7 meses
Puntos: 3
Mostrar datos en textbox

Tengo un problema de que no me ve ningun registro. antes lo usaba asi

echo "<input type =\"hidden\" name =\"ar_anio[".$i."]\" value=\"".$ar_anio[$i]."\">";

y ningun problema, ahora elimine el [i] de todos lados, y me funciona bien al ingresar un campo, pero al meterme a editar no me los muestra, les dejo el codigo

Código PHP:
<?php
//---> Items Inspeccion
//--->

  
echo "<table width=\"0%\" border=1 align=\"center\" cellpadding=4 cellspacing=0>";
  echo 
"<tr>";
  echo  
"<td class=\"dlcat\" align=center><a class=\"dlcat\"><font color=#0000ff>".rd_nomope."</font>";
  echo  
"<td class=\"dlcat\" align=center><a class=\"dlcat\"><font color=#0000ff>".rd_rut."</font>";
  echo  
"</a></td>";
  echo  
"<td class=\"dlcat\" align=center>";
  echo    
"<table border=0 width=100%><td align=center>";
  echo    
"</td></table>";
  echo    
"<table border=0 width=100%>";
  echo    
"<tr>";
  echo      
"<td class=\"dlcat\" align=center><a class=\"dlcat\"><font color=#0000ff>".rd_celular."</font></td>";
  echo    
"</tr>";
  echo    
"</table>";
  echo  
"</td>";
  echo  
"<td class=\"dlcat\" align=center><a class=\"dlcat\"><font color=#0000ff>".rd_equcer."</font>";
  echo  
"</a></td>";
  echo  
"<td class=\"dlcat\" align=center><a class=\"dlcat\"><font color=#0000ff>".rd_tiplic."</font>";
  echo  
"</a></td>";
  echo  
"<td class=\"dlcat\" align=center><a class=\"dlcat\"><font color=#0000ff>".rd_destino."</font>";
  echo  
"</a></td>";
  echo 
"</tr>";
  echo 
"<tr>";
  echo 
"<td>";
  echo 
"<input type =\"text\" name =\"ar_nomop\" size=20 maxlength =20 cellspacing=5 value=\"".$ar_nomop."\">";
  echo 
"</td>";
  echo 
"<td>";
  echo  
"<input type =\"text\" name =\"ar_rut\" size=12 maxlength = 10 value=\"".$ar_rut."\">";
  echo 
"</td>";
  echo 
"<td>";
  echo
"<table border=0 width=100%>";
  echo
" <tr><td>";
  echo 
"</td><td>";
  echo 
"<input type =\"text\" name =\"ar_celular\" size=10 maxlength = 80 value=\"".$row[op_cel]."\"> ";
  echo 
"</td><td>";    
  echo 
"</td></tr></table>";
  echo 
"</td>";
  echo 
"<td class=\"boxtext\" >";
  echo  
"<input type =\"text\" name =\"ar_equcer\" size=15 maxlength = 20 value=\"".$ar_equcer."\">";
  echo 
"</td>";
  echo 
"<td>";
  echo  
"<input type =\"text\" name =\"ar_tiplic\" size=15 maxlength = 20 value=\"".$ar_tiplic."\">";
  echo 
"</td>";
  echo 
"<td>";
  
//echo "$ar_rut";
//      echo  "<select name=\"ar_destino\">";
 //        $tok = strtok( lg_CbDestino, "," );
//         while( $tok ) {
 //          $selected = ($tok == $ar_destino)?"selected":"";
 //          echo "<option value=\"$tok\" $selected>$tok</option>";
 //          $tok = strtok( "," );
 //          }
 // echo  "</select>";
  
echo  "<input type =\"text\" name =\"ar_destino\" size=15 maxlength = 20 value=\"".$ar_destino."\">";
  echo 
"</td>";
  echo 
"</tr>";
  echo 
"<tr>";
  echo 
"<td class=\"dlcat\" class=\"dlcat\">&nbsp";
  echo 
"</td>";
  echo 
"<td class=\"dlcat\">&nbsp";
  echo 
"</td>";
  echo 
"<td class=\"dlcat\"><span class=\"boxtext\">";
  echo 
"</td>";
  echo 
"<td class=\"dlcat\">&nbsp";
  echo 
"</td>";
  echo 
"<td class=\"dlcat\">&nbsp";
  echo 
"</td>";
  echo 
"<td class=\"dlcat\" align=\"center\"><span class=\"boxtext\">";
  echo 
"</td>";
  echo 
"</tr>";
  echo 
"</table>";
?>


Esto viene de otro php creo que es bueno que lo vean.

Código PHP:
//--> Datos Items Inspeccion
//-->
    
$con_rpi "SELECT * FROM am_operador WHERE op_id='$f_folio'"
              
." ORDER BY op_id";
    
$ret      db_query($con_rpi) or die(db_error());
    
$num_resp db_num_rows($ret);


        
$ar_nomop  $row["op_nomop"];
        
$ar_rut  $row["op_rut"];
        
$ar_celular$row["op_cel"];
        
$ar_mandante  $row["op_mandante"];
        
$ar_inspector $row["op_inspector"];
        
$ar_resolu  $row["op_resolu"];
        
$ar_destino   $row["op_destino"];
        
$ar_equcer  $row["op_equcer"];
        
$ar_empresa $row["op_empresa"];
        
$ar_tiplic $row["op_tiplic"]; 
Gracias por la ayuda
  #2 (permalink)  
Antiguo 05/02/2008, 06:47
 
Fecha de Ingreso: enero-2008
Ubicación: Buenos Aires
Mensajes: 305
Antigüedad: 16 años, 3 meses
Puntos: 14
Re: Mostrar datos en textbox

Código PHP:
db_query($con_rpi
Tas seguro que esa sintaxis es valida?

yo conosco, mysql_query y mysql_db_query.
  #3 (permalink)  
Antiguo 05/02/2008, 06:53
Avatar de hulray  
Fecha de Ingreso: septiembre-2006
Mensajes: 630
Antigüedad: 17 años, 7 meses
Puntos: 3
Re: Mostrar datos en textbox

Segurisimo
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 17:49.