Ver Mensaje Individual
  #3 (permalink)  
Antiguo 19/01/2009, 13:05
onizuka2k
 
Fecha de Ingreso: noviembre-2007
Mensajes: 54
Antigüedad: 16 años, 5 meses
Puntos: 0
Respuesta: Alguien me puede decir como usar esto?

Mi funcion del JsCalendar esta asi...

Código:
              <script type="text/javascript">

  function dateChanged(calendar) {
    // Beware that this function is called even if the end-user only
    // changed the month/year.  In order to determine if a date was
    // clicked you can use the dateClicked property of the calendar:
   
	  
	if (calendar.dateClicked) {
      // OK, a date was clicked, redirect to /yyyy/mm/dd/index.php

	  var d = calendar.date.getDate();      // integer, 1..31
	  var y = calendar.date.getFullYear();
      var m = calendar.date.getMonth();     // integer, 0..11
      m = m + 1;
	  
      // redirect...
      //window.location = "/" + y + "/" + m + "/" + d + "/index.php";
	 ;
	  location.href = 'seleccion.php?event='+y+'-'+m+'-'+d+'&day='+d+'&mes='+m+'&year='+y;
    }
  };


  Calendar.setup(
    {
      flat         : "calendar-container", // ID of the parent element
      flatCallback : dateChanged           // our callback function
      dateStatusFunc: function(date){ // disable weekend days (Saturdays == 6 and Subdays == 0)
	  var today = new Date(); //alert(today.getTime());
	  return date.getDay() == 0 ||
	  (date.getTime() < today.getTime() - (1 * 24 * 60 * 60 * 1000) ||date.getTime() > today.getTime() + (90 * 24 * 60 * 60 * 1000));
	
	}
  );
                  </script>
y no me hace nada :S la parte del setup antes estaba asi y anda bien pero me habilita lo demas :S

Código:
  Calendar.setup(
    {
      flat         : "calendar-container", // ID of the parent element
      flatCallback : dateChanged           // our callback function
	
	}
  );

alguien ke me diga en ke estoy mal :S gracias