Ver Mensaje Individual
  #5 (permalink)  
Antiguo 13/10/2009, 05:10
oscargr
 
Fecha de Ingreso: octubre-2009
Mensajes: 41
Antigüedad: 14 años, 6 meses
Puntos: 0
Respuesta: Problema con el formulario

El codigo del formulario es:

<body>
<div id="wrap">
<div id="contactform">
<h1>Formulario de Contacto</h1>
<form id="contact-form" method="post" onsubmit="return emailCheck(this.email.value);" action="contacto/send.php">
<fieldset>
<legend>Datos Personales &raquo;</legend>
<div>
<label for="visitorname">
<span style="color:#c00;">*</span>Nombre:
</label>
<input type="text" name="name" id="visitorname" title="Su Nombre" value="<?php echo $name; ?>" />
</div>
<div>
<label for="visitorsurname">
<span style="color:#c00;">*</span>Apellidos:
</label>
<input type="text" name="surname" id="visitorsurname" title="Su Apellido" value="<?php echo $surname; ?>" />
</div>
<div>
<label for="visitormail">
<span style="color:#c00;">*</span>Direcci&oacute;n de correo:
</label>
<input type="text" name="email" id="visitormail" value="<?php echo $email; ?>" title="Su dirección de correo electr&oacute;nico" />
</div>
<div>
<label for="url">P&aacute;gina Web:</label>
<input type="text" name="url" id="url" class="text" title="Su página web, en caso de tenerla"/>
</div>
<div>
<label for="phone">Tel&eacute;fono:</label>
<input type="text" name="phone" id="phone" class="text" title="Su número de tel&eacute;fono"/>
</div>
<div>
<label for="postcode">C&oacute;digo Postal:</label>
<input type="text" name="postcode" id="postcode" class="text" title="El c&oacute;digo postal de su localidad"/>
</div>
<div>
<input type="submit" id="submit" name="send" value="Enviar &raquo;" title="Pulsa una vez para enviar el mensaje, y espera a la pantalla de confirmaci&oacute;n" />
</div>
</fieldset>
<fieldset>
<legend>Envienos su Mensaje &raquo;</legend>
<div>
<label for="subject">
<span style="color:#c00;">*</span>Motivo del Mensaje:
</label>
<input type="text" name="sub" id="subject" title="El motivo o titulo de su Mensaje" value="<?php echo $sub; ?>" />
</div>
<div>
<label for="notes">
<span style="color:#c00;">*</span>Cuerpo del Mensaje:
</label>
<textarea name="text" id="notes" rows="" cols="" onkeyup="val=this.value; if (val.length > 800) { alert('Lo siento, has sobrepasado el limite de 800 caracteres'); this.value = val.substring(0,800); } this.form.count.value=800-parseInt(this.value.length); "><?php echo $text; ?></textarea>
</div>
<div>
<label for="count">Caracteres disponibles:</label>
<input type="text" name="count" id="counter" value="800" size="2" />
<?php $text_len = preg_match_all('/./', $str, $dummy); ?>
</div>
</fieldset>
</form>
<p><span style="color:#c00;">*</span>Campos Obligatorios</p>
<p><span style="color:red;font-weight:bold;"><?php echo $error ?></span></p>
<script type="text/javascript" src="var.js"></script>
</div>
</div>
</body>