tngo una duda como tomo los datos del radio pero agregandolos a la misma tabla de informacion...
me refiero a q agrego el msj seleccion,opcion,telefono y E-Mail...pero no se tomar los valores del radio...
Help Plz n..n
aki van los datos:
index.html
Código HTML:
<html> <body> <center><br><font size="5" face="Verdana, Arial, Helvetica, sans-serif"><strong>Bienvenido a l2masterpiece</strong></font></br> </center> <center> <br><p><br><p><br><p><br><p><br><p><br><p> <a href="formulario.php"> <button><strong>Enviar PM</strong></button> </a> </center> <center> <br> <a href="modificar-usuario.php"> <button><strong>Modificar PM</strong></button> </a> </center> </body> </html>
Código PHP:
<html>
<body>
<br><center>Formulario(Envío de MP)</center></br>
<form action="insertar-registro.php" method="POST">
Mensaje:<textarea name="mensaje" cols="30" rows="3"></textarea><p>
Selección: <input name="col" type="radio" value="si"/> si
<input name="col" type="radio" value="no" checked/> no
<input name="col" type="radio" value="nose"/> nose <p>
Opción: <input type="checkbox" name="opc" value="ok">OK</input>
<input type="checkbox" name="opc" value="nada" checked>Nada</input> <p>
Teléfono: <input type="text" name="telefono">Acuérdate de usar solo números<p>
E-Mail: <input type="text" name="email"><p>
<input name="enviar" type="submit" value="enviar">
<input type="reset" name="limpiar">
</form>
</body>
</html>
Código PHP:
<?php
include"conexion.php";
$col = 'col';
if ($col == '1') {
$si;
} elseif ($col == '2') {
$no;
} elseif ($col == '3') {
$nose;
}
mysql_query("insert into clientesl2(mensaje, telefono, email) values ('{$_REQUEST['mensaje']}','{$_REQUEST['telefono']}','{$_REQUEST['email']}')");
?>
<html>
<body>
<b><hl><center><a href="index.html">indice</a></center></hl></b><br>
</body>
</html>