/*window_open*/

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

//20071130 webカタログ用追加
function MM_openBrWindow(theURL,winName,popupwidth,popupheight) { //v2.0
  if (navigator.userAgent.indexOf('Safari') >= 0) {
    window.open(theURL,winName,'width=' + (popupwidth + 1) + ',height=' + (popupheight + 1));
  } else {
    window.open(theURL,winName,'width=' + popupwidth + ',height=' + popupheight);
  }
}

//PDFカタログ用
function openPDF2(){
    f = confirm('22MBのPDFを別ウィンドウで開きます。よろしいですか？');
    if(f){
      window.open('./download/catalog_rev3.pdf','catalog_rev3','menubar=yes,toolbar=yes,status=yes,resize=yes,scrollbars=yes,location=yes');
    }
  }

/*ico-new*/
function daycount(tgtdy){
	ymd = tgtdy.split("/");
	today = (new Date()).getTime();
	tgday = (new Date(ymd[0],ymd[1]-1,ymd[2])).getTime();
	btday = Math.floor((tgday - today)/
	(24 * 60 * 60 * 1000));
	return btday + 1;
	}
	
	function newmark(tgtdy,deldy){
		//document.write("(" + tgtdy + ")");
		limdy = -daycount(tgtdy);
		if(deldy >= limdy){
			document.write("<img src='shared/images/ico_new.gif' class='ico-new' border='0'>");
			}
	}
