Ver Mensaje Individual
  #7 (permalink)  
Antiguo 15/02/2010, 01:35
gazaposa
 
Fecha de Ingreso: noviembre-2009
Mensajes: 209
Antigüedad: 14 años, 6 meses
Puntos: 0
Respuesta: envío de formulario

hola de nuevo, la pagina claro que se llama envia_form_php.php. pero cuando le doy a enviar me sigue sin funcionar, me dice que no se puede mostrar la pagina.
voy a poner de nuevo el codigo por si podeis ver alun error, muchas gracias

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Documento sin t&iacute;tulo</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_reloadPage(init) { //reloads the window if Nav4 resized
if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);
//-->
</script>
</head>

<body bgcolor="#0061AF">
<?php
if (! $_POST ){
?>

<div id="Layer1" style="position:absolute; left:28px; top:14px; width:261px; height:346px; z-index:1">
<form action="envia_form_php.php" method=post> '
<table width="98%" height="103" border="0" cellpadding="3">
<tr>
<td height="66" colspan="6">
<div align="center"><strong>FORMULARIO DE INSCRIPCI&Oacute;N</strong></div></td>
</tr>
<tr>
<td width="7%" height="31" valign="top">Nombre:</td>
<td width="23%">
<input type="text" name="nombre" size="25">
</td>
<td width="8%" valign="top">Apellidos:</td>
<td width="37%">
<input type="text" name="apellidos" size="35">
</td>
<td width="4%" valign="top">DNI:</td>
<td width="21%">
<input type="text" name="dni" size="21" align="right" alt="center">
</td>
</tr>
</table>
<table width="259%" border="0" cellpadding="3">
<tr>
<td width="9%" height="29" valign="top">Direcci&oacute;n:</td>
<td width="29%">
<input type="text" name="direccion"size="35" >
</td>
<td width="7%" valign="top">Tel&eacute;fono:</td>
<td width="22%">
<input type="text" name="textfield5" size="20">
</td>
<td width="6%" valign="top">Email:</td>
<td width="27%">
<input type="text" name="textfield6" >
</td>
</tr>
</table>
<table width="261%" border="0" cellpadding="3">
<tr>
<td width="23%" valign="top">Organismo/Universidad:</td>
<td width="35%">
<input type="text" name="organismo" size="38">
</td>
<td width="25%" valign="top">Tipo de participaci&oacute;n:</td>
<td width="17%">
<select name="participacion" size="1" >
<option>Comunicaci&oacute;n </option>
<option>P&oacute;ster </option>
<option>Oyente </option>
</select>
</td>
</tr>
</table>
<table width="170%" border="0" cellpadding="3">
<tr>
<td width="7%" valign="top">T&iacute;tulo:</td>
<td width="17%">
<input type="text" name="titulo" size="50">
</td>
<td width="30%" valign="top">Autores:</td>
<td width="46%">
<input type="text" name="autor" size="40">
</td>
</tr>
</table>
<table width="254%" border="0" cellpadding="3">
<tr>
<td width="23%" valign="top">Sesi&oacute;n Tem&aacute;tica:</td>
<td width="50%">
<input type="text" name="sesion" size="50">
</td>
<td width="7%" valign="top">Cuota:</td>
<td width="20%">
<input type="text" name="cuota" size="20">
</td>
</tr>
<?php
}else{
//Estoy recibiendo el formulario, compongo el cuerpo
$cuerpo = "Formulario enviado\n";
$cuerpo .= "Nombre: " . $_POST ["nombre"] . "\n";
$cuerpo .= "Apellidos: " . $_POST ["apellidos"] . "\n";
$cuerpo .= "DNI: " . $_POST ["dni"] . "\n";
$cuerpo .= "Dirección: " . $_POST ["direccion"] . "\n";
$cuerpo .= "Teléfono: " . $_POST ["telefono"] . "\n";
$cuerpo .= "Email: " . $_POST ["email"] . "\n";
$cuerpo .= "Organismo/Universidad: " . $_POST ["organismo"] . "\n";
$cuerpo .= "Participación: " . $_POST ["participacion"] . "\n";
$cuerpo .= "Título: " . $_POST ["titulo"] . "\n";
$cuerpo .= "Autores: " . $HTTP_POST_VARS["autor"] . "\n";
$cuerpo .= "Sesión: " . $_POST ["sesion"] . "\n";
$cuerpo .= "Cuota: " . $_POST ["cuota"] . "\n";

mail("[email protected]","Formulario recibido",$cuerpo);

echo "Gracias por rellenar el formulario. Se ha enviado correctamente.";
}
?>

</table>
<div id="Layer2" style="position:absolute; left:340px; top:336px; width:104px; height:43px; z-index:2">
<input type="submit" name="Submit" value="Enviar">
</div>

</form>
</div>
</body>
</html>