"Next Show Countdown"

  • Welcome to "The New" Wrestling Smarks Forum!

    I see that you are not currently registered on our forum. It only takes a second, and you can even login with your Facebook! If you would like to register now, pease click here: Register

    Once registered please introduce yourself in our introduction thread which can be found here: Introduction Board


Tzesi

The Artiste
Joined
Dec 18, 2011
Messages
753
Reaction score
14
Points
0
Put this code on the header

Code:
<script type="text/javascript">
//######################################################################################


dateFuture1 = new Date(2011,11,29,21,0,0);



//###################################
//nothing beyond this point
function GetCount(ddate,iid){

	dateNow = new Date();	//grab current date
	amount = ddate.getTime() - dateNow.getTime();	//calc milliseconds between dates
	delete dateNow;

	// if time is already past
	if(amount < 0){
		document.getElementById(iid).innerHTML="SmackDown is ON!";
	}
	// else date is still good
	else{
		days=0;hours=0;mins=0;secs=0;out="";

		amount = Math.floor(amount/1000);//kill the "milliseconds" so just secs

		days=Math.floor(amount/86400);//days
		amount=amount%86400;

		hours=Math.floor(amount/3600);//hours
		amount=amount%3600;

		mins=Math.floor(amount/60);//minutes
		amount=amount%60;

		secs=Math.floor(amount);//seconds

		out += days +" "+((days==1)?"day":"days")+", ";
		out += hours +" "+((hours==1)?"hour":"hours")+", ";
		out += mins +" "+((mins==1)?"min":"mins")+", ";
		out += secs +" "+((secs==1)?"sec":"secs")+", ";
		out = out.substr(0,out.length-2);
		document.getElementById(iid).innerHTML=out;

		setTimeout(function(){GetCount(ddate,iid)}, 1000);
	}
}

window.onload=function(){
	GetCount(dateFuture1, 'countbox1');
	
};
</script>
<div id="countbox1"></div>


Dates might be slightly off.
You will need to customize text color and size.
 

Solidus1

eXit
Joined
Dec 25, 2011
Messages
15,712
Reaction score
4,672
Points
0
Next PPV would be better imo, I assume most fans know that Smackdown is on at the same time every week.
 

Crayo

The Boss
Joined
Dec 16, 2011
Messages
63,815
Reaction score
6,080
Points
1
Location
United Kingdom of Ambrose
Website
wweforums.net
Thanks, but I think it will look ugly as just text. Might use it though to make a graphical clock counting downwards for example. Similar to the one on wwe.com with their PPV countdown. Also, debating whether to include SmackDown since it's taped, or just do RAW's/PPV's or even just PPV's.
 

Tzesi

The Artiste
Joined
Dec 18, 2011
Messages
753
Reaction score
14
Points
0
I will be writing a new code.
Wait for it :)
 

Solidus1

eXit
Joined
Dec 25, 2011
Messages
15,712
Reaction score
4,672
Points
0
Header is inappropriate too I think. A small ticker in the footer would be useful, but not invasive.
 

Lith

Jobber
Joined
Dec 19, 2011
Messages
236
Reaction score
9
Points
0
Side bar might take up too much space for smaller-screened users.
 

Anonymous

The Artiste
Joined
Dec 16, 2011
Messages
326
Reaction score
22
Points
0
Xa57q.png
 

Sage.

Champion
Joined
Jan 1, 2012
Messages
1,460
Reaction score
24
Points
0
Is this still getting implemented? That picture drawn up looks really good, and it'll be a really handy feature to have.