
14/11/2007, 07:19
|
| | Fecha de Ingreso: noviembre-2007
Mensajes: 51
Antigüedad: 17 años, 4 meses Puntos: 0 | |
Re: por que no funciona??? Pues nose como lo hice pero tengo 2 datos insertados en la BBdd y ahora algo cambie que no me los inserta...A ver si tu ves algo raro.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Documento sin título</title>
</head>
<body>
<div align="left">
<?php
if ($enviar) {
// process form
$link = mysql_connect("localhost", "root", "asge");
mysql_select_db("telefonos",$link);
$sql = "INSERT INTO 'telefonos_datos' ('NOMBRE_APELLIDOS', 'EXTEN_MOVIL', 'TLFNO', 'CABEZA_DE_GRUPO')";
$sql .= "VALUES ('".$nombre."', '".$extension."', '".$telefono."', '".$cabeza_grupo."')";
$result = mysql_query($sql,$link);
echo "¡Gracias! Hemos recibido sus datos.\n";
}else{
?>
</div>
<form method="post" action="<?$_SERVER['PHP_SELF']?>">
<div align="left">Nombre Apellidos:
<input type="Text" name="NOMBRE_APELLIDOS">
<br>
Extensión:
<input type="Text&quo>Dirección:<input type="Text" name="EXTEN_MOVIL">
<br>
Teléfono :
<input type="Text" name="TLFNO">
<br>
Cabeza de grupo :
<input type="Text" name="CABEZA_DE_GRUPO">
<br>
<input type="Submit" name="enviar" value="Aceptar información">
</div>
</form>
<div align="left">
<?php
} //end if
?>
</div>
</body>
</html> |