<!--
function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

//flash
function flash(CateStr, widthSWF, heightSWF) {
 document.write('<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0"  width="'+widthSWF+'" height="'+heightSWF+'" id=ShockwaveFlash1>')
 document.write('<param name="movie" value="'+CateStr+'">')
 document.write('<param name="menu" value="false">')
 document.write('<param name="quality" value="best">')
 document.write('<param name="wmode" value="transparent">')
 document.writeln('<embed src="'+CateStr+'" width="'+widthSWF+'" height="'+heightSWF+'" menu=false quality=best pluginspage="http://www.macromedia.com/go/getflashplayer" wmode="transparent" type="application/x-shockwave-flash"></embed>')
 document.writeln('</object>')
}

// object
function fn_e(id) { return document.getElementById(id); }

// navi
var isDOM = (document.getElementById ? true : false); 
var isIE4 = ((document.all && !isDOM) ? true : false); 
var isNS4 = (document.layers ? true : false); 
 
function getRef(id) 
{ 
        if (isDOM) return document.getElementById(id); 
        if (isIE4) return document.all[id]; 
        if (isNS4) return document.layers[id]; 
} 
 
var isNS = navigator.appName == "Netscape"; 
 
function moveRightEdge() 
{ 
        var yMenuFrom, yMenuTo, yOffset, timeoutNextCheck; 
        if (isNS4) 
        { 
                yMenuFrom   = layer1.top; 
                yMenuTo     = windows.pageYOffset + 350;
        } 
        else if (isDOM) 
        { 
                yMenuFrom   = parseInt (layer1.style.top, 0); 
                yMenuTo     = (isNS ? window.pageYOffset : document.body.scrollTop) + 350;
        } 
 
        timeoutNextCheck = 500; 
 
        if (yMenuFrom != yMenuTo) 
        { 
                yOffset = Math.ceil(Math.abs(yMenuTo - yMenuFrom) / 20); 
                if (yMenuTo < yMenuFrom) 
                        yOffset = -yOffset; 
                if (isNS4) 
                        layer1.top += yOffset; 
                else if (isDOM) 
                        layer1.style.top = parseInt (layer1.style.top, 10) + yOffset; 
                        timeoutNextCheck = 10; 
        } 
        setTimeout ("moveRightEdge()", timeoutNextCheck); 
} 

function goTop(orix,oriy,desx,desy)
	{
		var Timer;
		var winHeight = document.body.scrollTop;
		if(Timer) clearTimeout(Timer);
		startx = 0;
		starty = winHeight;
		if(!orix || orix < 0) orix = 0;
		if(!oriy || oriy < 0) oriy = 0;
		var speed = 7;
		if(!desx) desx = 0 + startx;
		if(!desy) desy = 0 + starty;
		desx += (orix - startx) / speed;
		if (desx < 0) desx = 0;
		desy += (oriy - starty) / speed;
		if (desy < 0) desy = 0;
		var posX = Math.ceil(desx);
		var posY = Math.ceil(desy);
		window.scrollTo(posX, posY);
		if((Math.floor(Math.abs(startx - orix)) < 1) && (Math.floor(Math.abs(starty - oriy)) < 1)){
			clearTimeout(Timer);
			window.scroll(orix,oriy);
		}else if(posX != orix || posY != oriy){
			Timer = setTimeout("goTop("+orix+","+oriy+","+desx+","+desy+")",15);
		}else{
			clearTimeout(Timer);
		}
	}

function newwin(url) {
	POP = window.open( url, 'WIN_SUB', 'status=0,scrollbars=yes,resizable=0,width=500,height=500');
	POP.focus();
}


// sigoto.php
//popup3 <img src="url" onClick="MM_openBrWindow('/map.html','','scrollbars=no,width=510,height=500')" style="cursor:pointer">
function MM_openBrWindow(theURL,winName,features) { //v2.0
	var win = window.open(theURL,winName,features);
	win.focus();
}

// write,edit
function writeSendIt(f) {
	if(!f.job.value) {
		alert('職種を入力してください.');
		f.job.focus();
		return false;
	}
	if(!f.employ.value) {
		alert('雇用形態を入力してください.');
		f.employ.focus();
		return false;
	}
	if(!f.pay.value) {
		alert('賃金を入力してください.');
		f.pay.focus();
		return false;
	}
	if(!f.ordering.value) {
		alert('整理番号を入力してください.');
		f.ordering.focus();
		return false;
	}
	if(!f.work.value) {
		alert('沿線・勤務地を入力してください.');
		f.work.focus();
		return false;
	}
	return true;
}

// delete
function Delete(mid) {
	var cfrm = confirm('削除しますか？');
	if(cfrm) {
		location.href = 'delete.php?mid=' + mid;
	}
}



//-->