// Modified by: Nick Malkiewicz
// Original Author: Eugene Vassiltsov

calendar = new Date();
day = calendar.getDay();
month = calendar.getMonth();
date = calendar.getDate();
year = calendar.getYear();
if (year < 1000)
year+=1900
cent = parseInt(year/100);
g = year % 19;
k = parseInt((cent - 17)/25);
i = (cent - parseInt(cent/4) - parseInt((cent - k)/3) + 19*g + 15) % 30;
i = i - parseInt(i/28)*(1 - parseInt(i/28)*parseInt(29/(i+1))*parseInt((21-g)/11));
j = (year + parseInt(year/4) + i + 2 - cent + parseInt(cent/4)) % 7;
l = i - j;
 
emonth = 3 + parseInt((l + 40)/44);
edate = l + 28 - 31*parseInt((emonth/4));
emonth--;
var dayname = new Array ("Sunday", "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday");
var monthname = new Array ("January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December" );

function todaysDate() 
{
document.writeln(dayname[day] + " ");
document.writeln(monthname[month] + " ");
//alert ("This is a Javascript Alert");
if (date< 10) document.write("0" + date + ", ");
  	else document.write(date + ", ");
document.writeln(year);
}

function reminder ()
{
// January
if ((month == 0) && (date >= 1) && (date <= 23 )) document.write("<p><strong>Sat Jan 23rd</strong> - <a href='/shows.php?date=jan2010_23'>NickNack at Beauty Bar</a></p>");
if ((month == 0) && (date >= 1) && (date <= 30 )) document.write("<p><strong>Sat Jan 30th</strong> - <a href='/shows.php?date=jan2010_30'>SneakView at The Independent</a></p>");
if ((month == 0) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Thu Feb 4th</strong> - <a href='/shows.php?date=feb2010_4'>NickNack at Blanton Museum</a></p>");
if ((month == 0) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Fri Feb 5th</strong> - <a href='/shows.php?date=feb2010_5'>NickNack at Blanton Museum</a></p>");
if ((month == 0) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Sat Feb 6th</strong> - <a href='/shows.php?date=feb2010_6'>NickNack at Zubar (Dallas)</a></p>");


// February
if ((month == 1) && (date >= 1) && (date <= 4 )) document.write("<p><strong>Thu Feb 4th</strong> - <a href='/shows.php?date=feb2010_4'>NickNack at Blanton Museum</a></p>");
if ((month == 1) && (date >= 1) && (date <= 5 )) document.write("<p><strong>Fri Feb 5th</strong> - <a href='/shows.php?date=feb2010_5'>NickNack at Blanton Museum</a></p>");
if ((month == 1) && (date >= 1) && (date <= 6 )) document.write("<p><strong>Sat Feb 6th</strong> - <a href='/shows.php?date=feb2010_6'>NickNack at Zubar (Dallas)</a></p>");
if ((month == 1) && (date >= 1) && (date <= 19 )) document.write("<p><strong>Fri Feb 19th</strong> - <a href='/shows.php?date=feb2010_19'>TMC and NickNack at Highball</a></p>");
if ((month == 1) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Wed Mar 17th</strong> - <a href='/shows.php?date=mar2010_17'>GigaCrate SXSW Pt 1</a></p>");
if ((month == 1) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Thur Mar 18th</strong> - <a href='/shows.php?date=mar2010_18'>GigaCrate SXSW Pt 2</a></p>");

// March
if ((month == 2) && (date >= 1) && (date <= 13 )) document.write("<p><strong>Sat Mar 13th</strong> - <a href='/shows.php?date=mar2010_13'>Frog Design SXSW Kick-Off</a></p>");
if ((month == 2) && (date >= 1) && (date <= 15 )) document.write("<p><strong>Mon Mar 15th</strong> - <a href='/shows.php?date=mar2010_15'>Sonos Smash Up Party</a></p>");
if ((month == 2) && (date >= 1) && (date <= 17 )) document.write("<p><strong>Wed Mar 17th</strong> - <a href='/shows.php?date=mar2010_17'>GigaCrate SXSW Pt 1</a></p>");
if ((month == 2) && (date >= 1) && (date <= 18 )) document.write("<p><strong>Thur Mar 18th</strong> - <a href='/shows.php?date=mar2010_18'>GigaCrate SXSW Pt 2</a></p>");
if ((month == 2) && (date >= 1) && (date <= 19 )) document.write("<p><strong>Fri Mar 19th</strong> - <a href='/shows.php?date=mar2010_19'>Frank151 SXSW Party</a></p>");


// April

// May
if ((month == 4) && (date >= 1) && (date <= 29 )) document.write("<p><strong>Fri May 29th</strong> - <a href='/shows.php?date=may2009_29'>BLAZE at 121 Bar</a></p>");
if ((month == 4) && (date >= 1) && (date <= 30 )) document.write("<p><strong>Sat May 30th</strong> - <a href='/shows.php?date=may2009_30'>BLAZE at Elephant Room</a></p>");
if ((month == 4) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Sat July 4th</strong> - <a href='/shows.php?date=july2009_4'>NickNack at The Boat Party</a></p>");

// June
if ((month == 5) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Sat July 4th</strong> - <a href='/shows.php?date=july2009_4'>NickNack at The Boat Party</a></p>");

// July
if ((month == 6) && (date >= 1) && (date <= 4 )) document.write("<p><strong>Sat July 4th</strong> - <a href='/shows.php?date=july2009_4'>NickNack at The Boat Party</a></p>");
if ((month == 6) && (date >= 1) && (date <= 18 )) document.write("<p><strong>Sat July 18th</strong> - <a href='/shows.php?date=july2009_18'>NickNack at Beauty Bar</a></p>");
if ((month == 6) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Fri Aug 14th</strong> - <a href='/shows.php?date=aug2009_14'>NickNack in-store Backspin Records</a></p>");

// August
if ((month == 7) && (date >= 1) && (date <= 7 )) document.write("<p><strong>Fri Aug 7th</strong> - <a href='/shows.php?date=aug2009_7'>NickNack at Malverde</a></p>");
if ((month == 7) && (date >= 1) && (date <= 14 )) document.write("<p><strong>Fri Aug 14th</strong> - <a href='/shows.php?date=aug2009_14'>NickNack in-store Backspin Records</a></p>");
if ((month == 7) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Fri Sept 4th</strong> - <a href='/shows.php?date=sept2009_4'>NickNack at Blanton Museum</a></p>");

// September
if ((month == 8) && (date >= 1) && (date <= 4 )) document.write("<p><strong>Fri Sept 4th</strong> - <a href='/shows.php?date=sept2009_4'>NickNack at Blanton Museum</a></p>");
if ((month == 8) && (date >= 1) && (date <= 24 )) document.write("<p><strong>Thur Sept 24th</strong> - <a href='/shows.php?date=sept2009_24'>NickNack, Digg, Prefuse 73 at Aces Lounge</a></p>");
if ((month == 8) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Fri Oct 2nd</strong> - <a href='/shows.php?date=oct2009_2'>NickNack at Blanton Museum</a></p>");
if ((month == 8) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Sat Oct 10th</strong> - <a href='/shows.php?date=oct2009_10'>BLAZE at Zilker Jazz Fest</a></p>");
if ((month == 8) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Fri Oct 16th</strong> - <a href='/shows.php?date=oct2009_16'>BLAZE at Central Market</a></p>");
if ((month == 8) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Sat Oct 17th</strong> - <a href='/shows.php?date=oct2009_17'>BLAZE at Elephant Room</a></p>");
if ((month == 8) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Wed Nov 4th</strong> - <a href='/shows.php?date=nov2009_4'>MikeSwing and NickNack at Dirty Bills</a></p>");
if ((month == 8) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Fri Nov 6th</strong> - <a href='/shows.php?date=nov2009_6'>NickNack at Blanton Museum</a></p>");
if ((month == 8) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Sat Nov 7th</strong> - <a href='/shows.php?date=nov2009_7'>TMC and NickNack at Plush</a></p>");

// October
if ((month == 9) && (date >= 1) && (date <= 2 )) document.write("<p><strong>Fri Oct 2nd</strong> - <a href='/shows.php?date=oct2009_2'>NickNack at Blanton Museum</a></p>");
if ((month == 9) && (date >= 1) && (date <= 10 )) document.write("<p><strong>Sat Oct 10th</strong> - <a href='/shows.php?date=oct2009_10'>BLAZE at Zilker Jazz Fest</a></p>");
if ((month == 9) && (date >= 1) && (date <= 16 )) document.write("<p><strong>Fri Oct 16th</strong> - <a href='/shows.php?date=oct2009_16'>BLAZE at Central Market</a></p>");
if ((month == 9) && (date >= 1) && (date <= 17 )) document.write("<p><strong>Sat Oct 17th</strong> - <a href='/shows.php?date=oct2009_17'>BLAZE at Elephant Room</a></p>");
if ((month == 9) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Sat Oct 31st</strong> - <a href='/shows.php?date=oct2009_31'>Halloween at The Independent</a></p>");
if ((month == 9) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Wed Nov 4th</strong> - <a href='/shows.php?date=nov2009_4'>MikeSwing and NickNack at Dirty Bills</a></p>");
if ((month == 9) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Fri Nov 6th</strong> - <a href='/shows.php?date=nov2009_6'>NickNack at Blanton Museum</a></p>");
if ((month == 9) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Sat Nov 7th</strong> - <a href='/shows.php?date=nov2009_7'>TMC and NickNack at Plush</a></p>");
if ((month == 9) && (date >= 1) && (date <= 31 )) document.write("<p><strong>Fri Nov 20th</strong> - <a href='/shows.php?date=nov2009_20'>The Cut Up at The Independent</a></p>");

// November
if ((month == 10) && (date >= 1) && (date <= 4 )) document.write("<p><strong>Wed Nov 4th</strong> - <a href='/shows.php?date=nov2009_4'>MikeSwing and NickNack at Dirty Bills</a></p>");
if ((month == 10) && (date >= 1) && (date <= 6 )) document.write("<p><strong>Fri Nov 6th</strong> - <a href='/shows.php?date=nov2009_6'>NickNack at Blanton Museum</a></p>");
if ((month == 10) && (date >= 1) && (date <= 7 )) document.write("<p><strong>Sat Nov 7th</strong> - <a href='/shows.php?date=nov2009_7'>TMC and NickNack at Plush</a></p>");
if ((month == 10) && (date >= 1) && (date <= 7 )) document.write("<p><strong>Wed Nov 11th</strong> - <a href='/shows.php?date=nov2009_11'>NickNack in Fayetteville</a></p>");
if ((month == 10) && (date >= 1) && (date <= 20 )) document.write("<p><strong>Fri Nov 20th</strong> - <a href='/shows.php?date=nov2009_20'>The Cut Up at The Independent</a></p>");
if ((month == 10) && (date >= 5) && (date <= 31 )) document.write("<p><strong>Fri Dec 4th</strong> - <a href='/shows.php?date=dec2009_4'>NickNack at Blanton Museum</a></p>");

// December
if ((month == 11) && (date >= 1) && (date <= 4 )) document.write("<p><strong>Fri Dec 4th</strong> - <a href='/shows.php?date=dec2009_4'>NickNack at Blanton Museum</a></p>");



}
