It is currently Fri 30 Sep 2016 - 13:44 - créer un forum

[TUTO]Compte à rebours pour vos forums

Skip to content

Post new topic Reply to topic Goto page: <  1, 2, 3, 4, 5, 6, 7  >

[TUTO]Compte à rebours pour vos forums
Author Message
Cerbère





PostPosted: Sun 16 Mar 2008 - 15:27    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

PublicitéSupprimer les publicités ?
Previous post review:

oui mais si tu regarde bien c'est marque:372 JOUR 3HEURES 58MINUTES 31sec avnat le prochain match

mai tu doit bien te douter que les match non pas lieu tout  les 372 jours
Author Message
themalin
Membre


Offline
Membre

Joined: 19 Apr 2006
Posts: 8,897
Point(s): 9,101
Moyenne: 1.02
Mac Firefox (ou l'un de ses dérivés : Minefield/Pale Moon/...)

PostPosted: Sun 16 Mar 2008 - 15:51    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

est ce que tu as bien programmé le compteur???
tu peux changer les valeur du code pour tomber sur la date voulue
_______________________


Forum
Author Message
Cerbère


Offline
Guest




PostPosted: Sun 16 Mar 2008 - 23:42    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

je ne sais pas programmé le compte a rebours

c'est pour cela que si tu pouvait me donner un coup de main sa serait cool( si sa te derange pas)


Author Message
themalin
Membre


Offline
Membre

Joined: 19 Apr 2006
Posts: 8,897
Point(s): 9,101
Moyenne: 1.02
Mac Firefox (ou l'un de ses dérivés : Minefield/Pale Moon/...)

PostPosted: Mon 17 Mar 2008 - 12:39    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

c'est expliqué dans le tuto

ici

function formatresults(){
if (this.timesup==false){//if target date/time not yet met
var displaystring=arguments[0]+" days "+arguments[1]+" hours "+arguments[2]+" minutes "+arguments[3]+"seconds left until March 23, 2009 18:25:00"

tu peux changer le jour pour mettre celui que tu veux
_______________________


Forum
Author Message
Cerbère


Offline
Guest




PostPosted: Mon 17 Mar 2008 - 13:14    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

je n'i arrive pas

Author Message
themalin
Membre


Offline
Membre

Joined: 19 Apr 2006
Posts: 8,897
Point(s): 9,101
Moyenne: 1.02
Mac Firefox (ou l'un de ses dérivés : Minefield/Pale Moon/...)

PostPosted: Mon 17 Mar 2008 - 13:18    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

quel jour veux tu mettre exactement comme jour 0
_______________________


Forum
Author Message
Cerbère


Offline
Guest




PostPosted: Mon 17 Mar 2008 - 13:21    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

6 pars exemple

Author Message
themalin
Membre


Offline
Membre

Joined: 19 Apr 2006
Posts: 8,897
Point(s): 9,101
Moyenne: 1.02
Mac Firefox (ou l'un de ses dérivés : Minefield/Pale Moon/...)

PostPosted: Mon 17 Mar 2008 - 13:26    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

ici

function formatresults(){
if (this.timesup==false){//if target date/time not yet met
var displaystring=arguments[0]+" days "+arguments[1]+" hours "+arguments[2]+" minutes "+arguments[3]+"seconds left until March 23, 2009 18:25:00"


tu remplaces par

function formatresults(){
if (this.timesup==false){//if target date/time not yet met
var displaystring=arguments[0]+" days "+arguments[1]+" hours "+arguments[2]+" minutes "+arguments[3]+"seconds left until March 06, 2009 18:25:00"

_______________________


Forum
Author Message
Cerbère


Offline
Guest




PostPosted: Mon 17 Mar 2008 - 19:54    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

ok c bon sa fonctionne mais je voudrai que le compteur soit comme sa 5 jour 2heure 30min 4SEC avant le prochain match au lieu de 5 jour 2heure 30min 4SEC avant le prochain match march 22 21h00min00sec

Author Message
themalin
Membre


Offline
Membre

Joined: 19 Apr 2006
Posts: 8,897
Point(s): 9,101
Moyenne: 1.02
Mac Firefox (ou l'un de ses dérivés : Minefield/Pale Moon/...)

PostPosted: Tue 18 Mar 2008 - 12:01    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

ici

+"seconds left until March 06, 2009 18:25:00"

tu supprimes le + et tu mets le reste à la ligne
_______________________


Forum
Author Message
Cerbère


Offline
Guest




PostPosted: Wed 19 Mar 2008 - 09:00    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

c'est bon comme sa

function formatresults(){
if (this.timesup==false){//if target date/time not yet met
var displaystring=arguments[0] +" jour "+arguments[1]+" heures "+arguments[2]+" minutes "+arguments[3]+"  
avant le prochain match March 22, 2008 21:00:00"
}
else{ //else if target date/time met
var displaystring="Future date is here!"
}
return displaystring
}

function formatresults2(){
if (this.timesup==false){ //if target date/time not yet met
var displaystring="<span class='lcdstyle'>"+arguments[0]+" <sup>days</sup> "+arguments[1]+" <sup>hours</sup> "+arguments[2]+" <sup>minutes</sup> "+arguments[3]

" <sup>seconds</sup></span> left until this Christmas"
}
else{ //else if target date/time met
var displaystring="" //Don't display any text
alert("Christmas is here!") //Instead, perform a custom alert
}


Author Message
themalin
Membre


Offline
Membre

Joined: 19 Apr 2006
Posts: 8,897
Point(s): 9,101
Moyenne: 1.02
Mac Firefox (ou l'un de ses dérivés : Minefield/Pale Moon/...)

PostPosted: Wed 19 Mar 2008 - 13:27    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

oui essayes avec ça
_______________________


Forum
Author Message
Cerbère


Offline
Guest




PostPosted: Wed 19 Mar 2008 - 15:36    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

sa ne fonctionne pas 

Author Message
FeeLs


Offline
Guest




PostPosted: Sun 6 Apr 2008 - 00:20    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote


Code: Sélectionner - Agrandir
<tr><td>
<div align="center"><br /><span class="copyright">{ADMIN_LINK}<br />

<!--
 We request you retain the full copyright notice below including the link to [url=http://www.phpbb.com]www.phpbb.com[/url].
 This not only gives respect to the large amount of time given freely by the developers
 but also helps build interest, traffic and use of phpBB 2.0. If you cannot (for good
 reason) retain the full copyright we request you at least leave in place the 
 Powered by phpBB line, with phpBB linked to [url=http://www.phpbb.com]www.phpbb.com[/url]. If you refuse 
 to include even this then support on our forums may be affected. 

   The phpBB Group : 2002 
// --> 
Powered by <a href="http://www.phpbb.com/" target="_phpbb" class="copyright">phpBB</a> &copy; 2001, 2005 phpBB Group<br />{TRANSLATION_INFO}<br />
<a href="http://www.mylimages.com/prive/index.php" target="_phpbb" class="copyright">Th&egrave;me r&eacute;alis&eacute; par <b>SGo</b></a></br>&nbsp;</br>&nbsp;</span></div>
  </td>
 </tr>
</table>


Je n'arrive pas trouver où il faut que je place le code :s
Merci d'avance

EDIT : Possible de mettre par exemple "Evenement le JJ/MM/AAAA soit dans JJ et HH:MM:SS" ?


Author Message
themalin
Membre


Offline
Membre

Joined: 19 Apr 2006
Posts: 8,897
Point(s): 9,101
Moyenne: 1.02
Mac Firefox (ou l'un de ses dérivés : Minefield/Pale Moon/...)

PostPosted: Sun 6 Apr 2008 - 12:03    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

bonjour  ajoutes le code au début du template
_______________________


Forum
Author Message
FeeLs


Offline
Guest




PostPosted: Sun 6 Apr 2008 - 13:31    Post subject: [TUTO]Compte à rebours pour vos forums Reply with quote

Code: Sélectionner - Agrandir
<html>
<body>
<style style="text/css">

.lcdstyle{ /*Example CSS to create LCD countdown look*/
background-color:black;
color:yellow;
font: bold 18px MS Sans Serif;
padding: 3px;
}

.lcdstyle sup{ /*Example CSS to create LCD countdown look*/
font-size: 80%
}

</style>

<script type="text/javascript">

/***********************************************
* Dynamic Countdown script- © Dynamic Drive (http://www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit http://www.dynamicdrive.com/ for this script and 100s more.
***********************************************/

function cdtime(container, targetdate){
if (!document.getElementById || !document.getElementById(container)) return
this.container=document.getElementById(container)
this.currentTime=new Date()
this.targetdate=new Date(targetdate)
this.timesup=false
this.updateTime()
}

cdtime.prototype.updateTime=function(){
var thisobj=this
this.currentTime.setSeconds(this.currentTime.getSeconds()+1)
setTimeout(function(){thisobj.updateTime()}, 1000) //update time every second
}

cdtime.prototype.displaycountdown=function(baseunit, functionref){
this.baseunit=baseunit
this.formatresults=functionref
this.showresults()
}

cdtime.prototype.showresults=function(){
var thisobj=this


var timediff=(this.targetdate-this.currentTime)/1000 //difference btw target date and current date, in seconds
if (timediff<0){ //if time is up
this.timesup=true
this.container.innerHTML=this.formatresults()
return
}
var oneMinute=60 //minute unit in seconds
var oneHour=60*60 //hour unit in seconds
var oneDay=60*60*24 //day unit in seconds
var dayfield=Math.floor(timediff/oneDay)
var hourfield=Math.floor((timediff-dayfield*oneDay)/oneHour)
var minutefield=Math.floor((timediff-dayfield*oneDay-hourfield*oneHour)/oneMinute)
var secondfield=Math.floor((timediff-dayfield*oneDay-hourfield*oneHour-minutefield*oneMinute))
if (this.baseunit=="hours"){ //if base unit is hours, set "hourfield" to be topmost level
hourfield=dayfield*24+hourfield
dayfield="n/a"
}
else if (this.baseunit=="minutes"){ //if base unit is minutes, set "minutefield" to be topmost level
minutefield=dayfield*24*60+hourfield*60+minutefield
dayfield=hourfield="n/a"
}
else if (this.baseunit=="seconds"){ //if base unit is seconds, set "secondfield" to be topmost level
var secondfield=timediff
dayfield=hourfield=minutefield="n/a"
}
this.container.innerHTML=this.formatresults(dayfield, hourfield, minutefield, secondfield)
setTimeout(function(){thisobj.showresults()}, 1000) //update results every second
}

/////CUSTOM FORMAT OUTPUT FUNCTIONS BELOW//////////////////////////////

//Create your own custom format function to pass into cdtime.displaycountdown()
//Use arguments[0] to access "Days" left
//Use arguments[1] to access "Hours" left
//Use arguments[2] to access "Minutes" left
//Use arguments[3] to access "Seconds" left

//The values of these arguments may change depending on the "baseunit" parameter of cdtime.displaycountdown()
//For example, if "baseunit" is set to "hours", arguments[0] becomes meaningless and contains "n/a"
//For example, if "baseunit" is set to "minutes", arguments[0] and arguments[1] become meaningless etc


function formatresults(){
if (this.timesup==false){//if target date/time not yet met
var displaystring=arguments[0]+" days "+arguments[1]+" hours "+arguments[2]+" minuts "+arguments[3]+"seconds left until "April 18, 2008 20:00:00"
}
else{ //else if target date/time met
var displaystring="Future date is here!"
}
return displaystring
}

function formatresults2(){
if (this.timesup==false){ //if target date/time not yet met
var displaystring="<span class='lcdstyle'>"+arguments[0]+" <sup>days</sup> "+arguments[1]+" <sup>hours</sup> "+arguments[2]+" <sup>minutes</sup> "+arguments[3]+" <sup>seconds</sup></span> left until this Christmas"
}
else{ //else if target date/time met
var displaystring="" //Don't display any text
alert("Christmas is here!") //Instead, perform a custom alert
}
return displaystring
}

</script>
<div id="countdowncontainer"></div>
<br />
<div id="countdowncontainer2"></div>

<script type="text/javascript">

var futuredate=new cdtime("countdowncontainer", "April 18, 2008 20:00:00")
futuredate.displaycountdown("days", formatresults)

</script>
</body>
</html>

<tr>
<td>
<div align="center"><br /><span class="copyright">{ADMIN_LINK}<br />

<!--
   We request you retain the full copyright notice below including the link to [url=http://www.phpbb.com]www.phpbb.com[/url].
   This not only gives respect to the large amount of time given freely by the developers
   but also helps build interest, traffic and use of phpBB 2.0. If you cannot (for good
   reason) retain the full copyright we request you at least leave in place the
   Powered by phpBB line, with phpBB linked to [url=http://www.phpbb.com]www.phpbb.com[/url]. If you refuse
   to include even this then support on our forums may be affected.

   The phpBB Group : 2002
// -->
Powered by <a href="http://www.phpbb.com/" target="_phpbb" class="copyright">phpBB</a> &copy; 2001, 2005 phpBB Group<br />{TRANSLATION_INFO}<br />
<a href="http://www.mylimages.com/prive/index.php" target="_phpbb" class="copyright">Th&egrave;me r&eacute;alis&eacute; par <b>SGo</b></a></br>&nbsp;</br>&nbsp;</span></div>
      </td>
   </tr>
</table>

<!-- DEBUT DU SCRIPT -->
<style type="text/css">
.ejs_context_menuitems{padding-left:12px; padding-right:7px; }
</style><script language="JavaScript1.2">
/*
SCRIPT EDITE SUR L'EDITEUR JAVASCRIPT
http://www.editeurjavascript.com
*/
ejs_context_elemt = new Array;
ejs_context_elemt[0] = "Page précédente|history.go(-1)";
ejs_context_elemt[1] = "Page suivante|history.go(1)";
ejs_context_elemt[2] = "";
ejs_context_elemt[3] = 'Portail|document.location.href=\'http://lecafedemarseille.xooit.fr/portal.php\'';
ejs_context_elemt[4] = 'Forums|document.location.href=\'http://lecafedemarseille.xooit.fr/index.php\'';
ejs_context_elemt[5] = 'F.A.Q|document.location.href=\'http://lecafedemarseille.xooit.fr/faq.php\'';
ejs_context_elemt[6] = 'Recherche|document.location.href=\'http://lecafedemarseille.xooit.fr/search.php\'';
ejs_context_elemt[7] = 'Membres|document.location.href=\'http://lecafedemarseille.xooit.fr/memberlist.php\'';
ejs_context_elemt[8] = 'Groupes|document.location.href=\'http://lecafedemarseille.xooit.fr/groupcp.php\'';
ejs_context_elemt[9] = 'Profil|document.location.href=\'http://lecafedemarseille.xooit.fr/profile.php?mode=editprofile\'';
ejs_context_elemt[10] = '';
ejs_context_elemt[11] = 'Administration|document.location.href=\'http://lecafedemarseille.xooit.com/admin/index.php\'';
ejs_context_elemt[12] = 'Support|document.location.href=\'http://xooit.xooit.com\'';
ejs_context_elemt[13] = 'PhpBB.com|document.location.href=\'http://phpbb.com\'';
function ejs_context_position(e)
 {
 ejs_context_x = (navigator.appName.substring(0,3) == "Net") ? e.pageX : event.x+document.body.scrollLeft;
 ejs_context_y = (navigator.appName.substring(0,3) == "Net") ? e.pageY : event.y+document.body.scrollTop;
 }

function ejs_context_open()
 {
 document.getElementById("ejs_context_box").style.top = ejs_context_y;
 document.getElementById("ejs_context_box").style.left = ejs_context_x;
 document.getElementById("ejs_context_ombre").style.top = ejs_context_y+2;
 document.getElementById("ejs_context_ombre").style.left = ejs_context_x+2;
 document.getElementById("ejs_context_box").style.visibility = "visible";
 document.getElementById("ejs_context_ombre").style.visibility = "visible";
 return(false);
 }

function ejs_context_close()
 {
 if (document.getElementById)
  {
  document.getElementById("ejs_context_box").style.top = 0;
  document.getElementById("ejs_context_box").style.left = 0;
  document.getElementById("ejs_context_ombre").style.top = 0;
  document.getElementById("ejs_context_ombre").style.left = 0;
  document.getElementById("ejs_context_box").style.visibility = "hidden";
  document.getElementById("ejs_context_ombre").style.visibility = "hidden";
  }
 }

function ejs_context_hl(mode, element)
 {
 if(mode == 1)
  {
  element.style.background = '#316AC5';
  element.style.color = '#ffffff';
  }
 else
  {
  element.style.background ='#ffffff';
  element.style.color = '#000000';
  }
 }

if(navigator.appName.substring(0,3) == "Net")
 document.captureEvents(Event.MOUSEMOVE);
</script>
<!-- FIN DU SCRIPT -->
<!-- DEBUT DU SCRIPT -->
<div id=ejs_context_box style="z-index:500;position:absolute;width:200px; border:1px solid #9D9DA1; background-color:#ffffff; font-family:Microsoft sans serif; font-size:12px; cursor:default; visibility:hidden;padding:3">
<script language="JavaScript">
/*
SCRIPT EDITE SUR L'EDITEUR JAVASCRIPT
http://www.editeurjavascript.com
*/
ejs_context_ombre_txt = '';
for(a=0;a<ejs_context_elemt.length;a++)
 {
 if(ejs_context_elemt[a].indexOf("|") > 0)
  {
  splited = new Array;
  splited = ejs_context_elemt[a].split("|");
  document.write('<div class="ejs_context_menuitems" onClick="'+splited[1]+'" onMouseOver="ejs_context_hl(1, this)" onMouseOut="ejs_context_hl(0, this)">'+splited[0]+'</div>');
  ejs_context_ombre_txt += '<div class="ejs_context_menuitems">'+splited[0]+'</div>';
  }
 else
  {
  document.write('<div class="ejs_context_menuitems" onClick="'+splited[1]+'" onMouseOver="ejs_context_hl(1, this)" onMouseOut="ejs_context_hl(0, this)"><hr width="195" size="1" color="9D9DA1" /></div>');
  ejs_context_ombre_txt += '<div class="ejs_context_menuitems"><hr width="195" size="1" color="9D9DA1" /></div>';
  }
 }
document.write('</div><div id=ejs_context_ombre style="z-index:400;position:absolute;width:200px; border:1px solid #9D9DA1; background-color:#9D9DA1; font-family:Microsoft sans serif; font-size:12px; color:#9D9DA1 ;cursor:default; visibility:hidden;padding:3">'+ejs_context_ombre_txt+'</div>');

// EVENEMENTS
document.onmousemove = ejs_context_position;
document.oncontextmenu = ejs_context_open;
document.onclick = ejs_context_close;
</script>
<!-- FIN DU SCRIPT -->
 


Rien ne s'affiche :/


Author Message
Contenu Sponsorisé





PostPosted: Today at 13:44    Post subject: [TUTO]Compte à rebours pour vos forums

Display posts from previous:   
Reply to topic Page 3 of 7 Goto page: <  1, 2, 3, 4, 5, 6, 7  >




Portal | Index | Administration Panel | Create a forum | Free support forum | Free forums directory | Report a violation | Conditions générales d'utilisation
Propulsé par p h p B B © 2016 p h p B B Group |
 
© 2003-2013 Xooit.com - Contact - Mentions légales - CGU - Charte - CNIL : 1381401