Hola de nuevo!
El formulario se encuentra aqui:
http://www.firenetworks.eu/Formulario/index.php
Como se puede ver, al presionar el calendario de jscalendar, no funciona...
He aqui el código:
Código HTML:
Ver original<!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">
<?php
//User info (DO NOT EDIT!)
$name = stripslashes($_POST['name']); //sender's name
$email = stripslashes($_POST['email']); //sender's email
//The subject
$subject = "[Formulario de Contacto] "; //The default subject. Will appear by default in all messages. Change this if you want.
$subject .= stripslashes($_POST['subject']); // the subject
//The message you will receive in your mailbox
//Each parts are commented to help you understand what it does exaclty.
//YOU DON'T NEED TO EDIT IT BELOW BUT IF YOU DO, DO IT WITH CAUTION!
$msg = "De : $name \r\n"; //add sender's name to the message
$msg .= "e-mail : $email \r\n"; //add sender's email to the message
$msg .= "Asunto : $subject \r\n\n"; //add subject to the message (optional! It will be displayed in the header anyway)
$msg .= "---Mensaje--- \r\n".stripslashes($_POST['message'])."\r\n\n"; //the message itself
//Extras: User info (Optional!)
//Delete this part if you don't need it
//Display user information such as Ip address and browsers information...
$msg .= "---User information--- \r\n"; //Title
$msg .= "User IP : ".$_SERVER["REMOTE_ADDR"]."\r\n"; //Sender's IP
$msg .= "Browser info : ".$_SERVER["HTTP_USER_AGENT"]."\r\n"; //User agent
$msg .= "User come from : ".$_SERVER["HTTP_REFERER"]; //Referrer
// END Extras
?>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <link rel="stylesheet" href="css/main.css" type="text/css" media="screen" /> <link href="css/calendar.css" type="text/css" rel="stylesheet">
<script type="text/javascript" src="js/mootools.js"></script>
<!-- Formcheck2 / Moo.Floor.ch -->
<!-- http://moo.floor.ch/?p=18 -->
<script type="text/javascript" src="js/formcheck.js"></script> <script type="text/javascript">
window.addEvent('domready', function(){check = new FormCheck('third', {
display : {
fadeDuration : 500,
errorsLocation : 1,
indicateErrors : 1,
showErrors : 1
}
})});
<script type="text/javascript" src="js/niceforms.js"></script>
<!--
body {
background-color: #FFF;
}
-->
<!-- The contact form starts here-->
<?php
if ($_SERVER['REQUEST_METHOD'] != 'POST'){
$self = $_SERVER['PHP_SELF'];
?>
<!-- Start HTML form -->
<form name="form" method="post" id="third" action="<?php echo $self;?>" class="niceform">
<h1>Formulario de contacto
</h1>
<!-- Name -->
<input id="name" name="name" type="text" class="validate['required','length[3,-1]','nodigit']" size="20" />
<!-- Email -->
<input id="email" name="email" type="text" class="validate['required','length[5,-1]','email']" size="20" />
<!-- Website -->
<script src="js/calendar.js" type="text/javascript"></script> <script src="js/calendar-es.js" type="text/javascript"></script> <script src="js/calendar-setup.js" type="text/javascript"></script> <input type="text" name="ingreso" id="ingreso" value="dd-mm-yyyy" size="15"/> <img src="images/calendario.png" width="16" height="16" border="0" title="Fecha Inicial" id="lanzador"> <!-- script que define y configura el calendario-->
<script type="text/javascript"> Calendar.setup({
inputField : "ingreso", // id del campo de texto
ifFormat : "%d-%m-%Y", // formato de la fecha que se escriba en el campo de texto
button : "lanzador" // el id del botón que lanzará el calendario
});
<!-- Subject -->
<input id="subject" name="subject" type="text" class="validate['required']" size="20" />
<!-- Message -->
<textarea id="message" name="message" type="text" class="validate['required']" rows="10" cols="30"></textarea>
<!-- Spam Check -->
<label for="spamcheck"><span class="blue">*
</span> <acronym title="[ Spam prevention ]">Cuanto es la suma?
</acronym> :
<span class="blue"> 2 + 3 = ???
</span> <input id="spamcheck" name="spamcheck" type="text" size="5" class="validate['required','number','spamcheck']" />
<input type="submit" class="buttonSubmit" value="Enviar!" />
<!-- Niceforms: mouse over effect -->
<!-- Do not remove the line below -->
<div id="stylesheetTest"></div>
<?php
} else {
error_reporting(0);
if (mail($to, $subject, $msg, "From: $email\r\nReply-To: $email\r\nReturn-Path: $email\r\n"))
//Message sent!
//It the message that will be displayed when the user click the sumbit button
//You can modify the text if you want
echo nl2br("
<div class=\"MsgSent\">
<p>Muchas gracias
<b><?=$name;?></b>, tu mensaje ha sido enviado!
<br /> Te responderemos a la mayor brevedad.
</p>
");
else
// Display error message if the message failed to send
echo "
<p>Sorry
<b><?=$name;?></b>, your message failed to send. Try later!
</p>
}
?>