Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
- <html>
- <head>
- <title>Mándanos tus comentarios</title>
- <style type="text/css">
- <!--
- body {
- background: url(images/fondo_form_carla.png);
- background-color: #343434;
- }
- .style4 {font-size: 12px;}
- .style5 {font-size: 10px; font-family: Verdana, Arial, Helvetica, sans-serif; }
- .style6 {font-family: Verdana, Arial, Helvetica, sans-serif}
- .style7 {color: #FFFFFF}
- .style8 {font-size: 9px; font-family: Verdana, Arial, Helvetica, sans-serif; padding-top:2px;}
- a:link {
- color: #FFFFFF;
- }
- a:visited {
- color: #FFFFFF;
- }
- a:hover {
- color: #FFFFFF;
- }
- a:active {
- color: #FFFFFF;
- }
- #limpiar {
- margin-left:130px;
- *width: 130px;
- }
- #enviar {
- margin-right:100px;
- *width: 115px;
- }
- -->
- </style>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
- <script type="text/javascript">
- <!--
- function MM_validateForm() { //v4.0
- if (document.getElementById){
- var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;
- for (i=0; i<(args.length-2); i+=3) { test=args[i+2]; val=document.getElementById(args[i]);
- if (val) { nm=val.name; if ((val=val.value)!="") {
- if (test.indexOf('isEmail')!=-1) { p=val.indexOf('@');
- if (p<1 || p==(val.length-1)) errors+='- '+nm+' must contain an e-mail address.\n';
- } else if (test!='R') { num = parseFloat(val);
- if (isNaN(val)) errors+='- '+nm+' must contain a number.\n';
- if (test.indexOf('inRange') != -1) { p=test.indexOf(':');
- min=test.substring(8,p); max=test.substring(p+1);
- if (num<min || max<num) errors+='- '+nm+' must contain a number between '+min+' and '+max+'.\n';
- } } } else if (test.charAt(0) == 'R') errors += '- '+nm+' : Este campo es necesario.\n'; }
- } if (errors) alert('Los siguientes campos son erroneos:\n'+errors);
- document.MM_returnValue = (errors == '');
- } }
- //-->
- </script>
- </head>
- <body>
- <?
- if (!($HTTP_POST_VARS)){
- ?>
- <form id="form1" name="form1" method="post" action="">
- <table width="500" border="0" align="center" cellpadding="0" cellspacing="5">
- <tr>
- <td colspan="2" class="style5"><div align="center" class="style4 style6 style7"><strong>Contáctenos:</strong><br>
- Su Opinion es Importante Para Nosotros<br>
- </div></td>
- </tr>
- <tr>
- <td colspan="2" class="style5"><hr class="style4"></td>
- </tr>
- <tr>
- <td height="34" width="139" class="style5 style6 style7">Nombre Completo:</td>
- <td width="389" class= "style5"><input name="Nombre_Completo" type="text" id="Nombre_Completo" onBlur="MM_validateForm('Nombre_Completo','','R','Telefono','','R','Email','','RisEmail');return document.MM_returnValue" size="40" /></td>
- </tr>
- <tr>
- <td height="34" class="style5 style6 style7">Teléfono de Contacto:</td>
- <td><table width="226" border="0" class="style5" cellspacing="0" cellpadding="0">
- <tr>
- <td class="style5"><input name="Telefono" type="text" id="Telefono" /></td>
- </tr>
- <tr>
- <td class="style8 style7"><div align="left">Ej: 0212-1234567</div></td>
- </tr>
- </table></td>
- </tr>
- <tr>
- <td height="34" class="style5 style6 style7">E-Mail:</td>
- <td class="style5"><input name="Email" type="text" class="style5" id="Email" size="40" /></td>
- </tr>
- <tr>
- <td class="style5 style6 style7">Comentarios:</td>
- <td class="style5"><textarea name="Comentarios" cols="45" rows="5" class="style5" id="Comentarios"></textarea></td>
- </tr>
- <tr>
- <td colspan="2" class="style5"><table width="500" border="0" align="center" cellpadding="1" cellspacing="4">
- <tr>
- <td width="323" class="style4 style6 style7"><div>
- <input name="Limpiar" type="submit" id="Limpiar" value="Limpiar Formulario">
- </div></td>
- <td width="300" class="style4 style6 style7"><div><input name="enviar" type="submit" id="enviar" value="Enviar Formulario" ></div></td>
- </tr>
- </table></td>
- </tr>
- </table>
- </form>
- <p>
- <?
- }else{
- //Estoy recibiendo el formulario, compongo el cuerpo
- $cuerpo = "****************************************************************\n";
- $cuerpo .= " CONTACTO\n";
- $cuerpo .= "****************************************************************\n";
- $cuerpo .= "Nombre Completo : " . $HTTP_POST_VARS["Nombre_Completo"] . "\n";
- $cuerpo .= "Teléfono de Contacto: " . $HTTP_POST_VARS["Telefono"]."\n";
- $cuerpo .= "Correo Electrónico : " . $HTTP_POST_VARS["Email"] . "\n";
- $cuerpo .= "Comentarios : " . $HTTP_POST_VARS["Comentarios"] . "\n";
- $cuerpo .= "****************************************************************\n";
- //mando el correo...
- mail("carla_andreina@hotmail.com","Formulario de Contacto Recibido",$cuerpo);
- mail("chispu@hotmail.com","Formulario de Contacto Recibido",$cuerpo);
- mail("danielpages@gmail.com","Formulario de Contacto Recibido",$cuerpo);
- //doy las gracias por el envío
- echo("
- <p align=center>
- <span class=style5><img src="images/gracias.png" width=110 height=26 /><br />
- </span><span class=style6 style7>Responderemos su contacto a la brevedad posible</span></p>
- <p align=center class=style6><span class=style7><a href="">Haga Click aquí para continuar</a> </span>
- </p>");
- }
- ?>
- </body>
- </html>
Add Comment
Please, Sign In to add comment