remonter home remonter

MooCountdown – v0.2

MooCountdown (mootools countdown) -v 0.2 [English]

Here is the latest version of the script.

It does not change the possibilities of the script at present. The structure of the code was improved, some correctives were brought because there was a bug on IE.

The declaration and the instanciation of the class saw itself simplified too. Fewer options (use of array), simpler legibility.

Changelog :

  • + Decomposition in 1 class mother ( MooCountdown) and 2 class girls: MooCountdown.Date which manages a countdown from now to a precise date and MooCountdown.Countdown which manages the simple countdown of seconds.
  • + Correction of the Tween effect to work under IE 7 +
  • + Care of the notion of year

Download

Demo

The new demo is here : démo MooCountDown v0.2

Instanciation :

  1. window.addEvent(‘domready’, function() {
  2.  
  3.         //demo 1
  4.  
  5.         new MooCountdown.Date($(‘countdown’),{
  6.             date: ’06/11/2010 00:00am’,
  7.             text:[' Year ',' Days ',' Hours ',' Minutes ',' Seconds '],
  8.             startFont : 20,
  9.             finishFont : 40,
  10.             onComplete: function () {
  11.                 alert(‘Terminé’);
  12.             }
  13.         });
  14.  
  15.         //demo 2
  16.  
  17.         new MooCountdown.CountDown($(‘countdown_2′),{
  18.             number: 10,
  19.             startFont : 20,
  20.             finishFont : 40,
  21.             onComplete: function () {
  22.                 alert(‘Terminé’);
  23.             }
  24.         });
  25.  
  26.       });

Remerciements

Thanks to Tlkshadow for the corrective and the assistant for the division.

MooCountdown (mootools compte à rebours) -v 0.2 [Français]

Voici la dernière mouture du script.

Elle ne change pas les possibilités du script actuellement. La structure du code a été améliorée, quelques correctifs ont été apportés car il y avait un bug sur IE.

La déclaration et l’instanciation de la classe s’est vue simplifiée elle aussi. Moins d’options (utilisation de tableaux), lisibilité plus simple.

Changelog :

  • + Décomposition en 1 classe mère (MooCountdown) et 2 classes filles : MooCountdown.Date qui gère un décompte de maintenant à une date précise et MooCountdown.Countdown qui gère le décompte simple de secondes.
  • + Correction de l’effet Tween pour le faire fonctionner sous IE 7+
  • + Prise en charge de la notion d’année

Téléchargement

Démo

La démo se trouve là : démo MooCountDown v0.2

Instanciation :

  1. window.addEvent(‘domready’, function() {
  2.  
  3.         //demo 1
  4.  
  5.         new MooCountdown.Date($(‘countdown’),{
  6.             date: ’06/11/2010 00:00am’,
  7.             text:[' An ',' Jours ',' Heures ',' Minutes ',' Secondes '],
  8.             startFont : 20,
  9.             finishFont : 40,
  10.             onComplete: function () {
  11.                 alert(‘Terminé’);
  12.             }
  13.         });
  14.  
  15.         //demo 2
  16.  
  17.         new MooCountdown.CountDown($(‘countdown_2′),{
  18.             number: 10,
  19.             startFont : 20,
  20.             finishFont : 40,
  21.             onComplete: function () {
  22.                 alert(‘Terminé’);
  23.             }
  24.         });
  25.  
  26.       });

Remerciements

Merci à Tlkshadow pour le correctif et l’aide pour le découpage.

Billets similaires

Un commentaire pour “MooCountdown – v0.2”

  1. [...] Comme vous avez pu le remarquer, la v0.2 du MooCountdown est sortie. Je l’ai mis à disposition ici : MooCountdown 0.2 [...]



Laissez un commentaire

Connect with Facebook