// Print Update Script

function printdate(yy,mm,dd,type,addtxt){
wnew= new Array(4);
var SysDate = new Date(); 
var UpDate=new Date(yy,mm-1,dd);
var pasttime=SysDate.getTime()-UpDate.getTime();
pastdate=(Math.floor(pasttime/(24*60*60*1000)));

if (pastdate<=7){
	newmark="<IMG SRC='/img/new.gif' alt='NEW' width=28 height=9 hspace=2 border=0>";
	fontcl="<FONT color='#EA5F47'>";
}
else {
	newmark="";
	fontcl="<FONT color='#261F8B'>";
};

wnew[0]="［"+(yy)+"年"+(mm)+"月"+(dd)+"日"+(addtxt)+"］"+(newmark);
wnew[1]="(出題日"+(yy)+"/"+(mm)+"/"+(dd)+")"+(newmark);
wnew[2]=(fontcl)+"(出題日"+(yy)+"/"+(mm)+"/"+(dd)+(newmark)+")"+"</FONT>";
wnew[3]=(newmark);
wnew[4]="";

document.write (wnew[type]);
}
