Ver Mensaje Individual
  #1 (permalink)  
Antiguo 02/07/2012, 13:37
cardf
 
Fecha de Ingreso: abril-2012
Ubicación: chile
Mensajes: 33
Antigüedad: 12 años
Puntos: 0
como cargar datos de un usuario registrado a un formulario para actualizar sus datos

Hola amigo quisiera hacerles una consulta , como puedo cargar datos de un usuario registrado aun formulario para que el pueda actualizar sus datos

el codigo

<?php


$conexion = mysql_connect("localhost", "root", "");

mysql_select_db("prueba", $conexion);

$consulta = "SELECT * FROM usuarios where correo_electronico='".$busqueda."'";

$resultado = mysql_query($consulta, $conexion) or die(mysql_error());

$datos= mysql_fetch_array($resultado);

echo "<center>";

echo "<form action=\"actualizar3.php\" method=\"post\">";

echo "<table width=\"200\" border=\"1\">";
echo "<tr>";
echo "<td>";
echo "correo";
echo "</td>";
echo "<td>";
echo "<input type=\"text\" name=\"correo_electronico\" value=\"".$datos['correo_electronico']."\" id=\"correo_electronico\" size=\"40\" maxlength=\"20\" />";
echo "</td>";
echo "</tr>";

echo "<tr>";
echo "<td>";
echo "nombre";
echo "</td>";
echo "<td>";
echo "<input type=\"text\" name=\"nombre\" value=\"".$datos['nombre']."\" id=\"nombre\" size=\"40\" maxlength=\"40\" />";
echo "</td>";
echo "</tr>";



echo "<tr>";
echo "<td>";
echo "apellido";
echo "</td>";
echo "<td>";
echo "<input type=\"text\" name=\"apellido\" value=\"".$datos['apellido']."\" id=\"apellido\" size=\"40\" maxlength=\"40\" />";
echo "</td>";
echo "</tr>";

echo "</table>";

echo "<input type=\"submit\" name=\"actualizar\" value=\"actualizar\" />";

echo "</form>";

echo "<center>";


?>
que mas me falta si alguien puede ayudarme gracias