
function openWin(){
	
	name1 = document.eFormbishutc.F01.value;
    age  = document.eFormbishutc.F03.value;
    zip1 = document.eFormbishutc.F04.value;
    zip2 = document.eFormbishutc.F05.value;
    adr1 = document.eFormbishutc.F06.value;
    cmp  = document.eFormbishutc.F07.value;
    pst  = document.eFormbishutc.F08.value;
    wYr  = document.eFormbishutc.F09.value;
    zip3 = document.eFormbishutc.F10.value;
    zip4 = document.eFormbishutc.F11.value;
    adr2 = document.eFormbishutc.F12.value;
    tel1 = document.eFormbishutc.F13.value;
    tel2 = document.eFormbishutc.F14.value;
    fax1 = document.eFormbishutc.F15.value;
    fax2 = document.eFormbishutc.F16.value;
    eml1 = document.eFormbishutc.F17.value;
    eml2 = document.eFormbishutc.F18.value;

	var n1 = document.eFormbishutc.F19.selectedIndex;
    crs    = document.eFormbishutc.F19.options[n1].value;
	
	var n2 = document.eFormbishutc.F20.selectedIndex;
    kDy    = document.eFormbishutc.F20.options[n2].value;

    Memb = document.eFormbishutc.F21.value;

    
	//NoInputCheck
	if (name1 == ''){
		alert ('氏名を入力して下さい。');
		document.eFormbishutc.F01.focus();
		return;
	}
	if (tel1=='' && tel2=='' && fax1=='' && fax2=='' && eml1=='' && eml2==''){
		alert ('連絡先を入力して下さい。');
		document.eFormbishutc.F13.focus();
		return;
	}
	if (crs == '0'){
		alert ('受講希望講座を選択して下さい。');
		document.eFormbishutc.F19.focus();
		return;
	}
	if (kDy == '0'){
		alert ('希望日を選択して下さい。');
		document.eFormbishutc.F20.focus();
		return;
	}


	//sex
	sex = ""
	for (i = 0; i < 2; i++){
		if (document.eFormbishutc.F02[i].checked){
			sex = document.eFormbishutc.F02[i].value;
		}
	}
	switch(sex){
	case 'Male':
		sex='男性';break;
	case 'Female':
		sex='女性';break;
	case '':
		sex='<br>';
	}
	
	
	//slp
	slp = ""
	for (i = 0; i < 2; i++){
		if (document.eFormbishutc.F22[i].checked){
			slp = document.eFormbishutc.F22[i].value;
		}
	}
	switch(slp){
	case '':
		slp='<br>';break;
	case 'HotelYes':
		slp='希望する';break;
	case 'HotelNo':
		slp='希望しない';
	}


	//age
	if (age==''){
		age='<br>';
	}
	else{
		age= age + '歳';
	}


	//Memb
    if (Memb=='') Memb='<br>';
    Memb = Memb.replace(/\n/g,"<br>");


	//crs
	switch(crs){
	case 'CourseOne':
		crs='基本コース：75,000円';break;
	case 'CourseTwo':
		crs='入社前基礎講座コース：18,000円';
	}
	
	

	SubWin = window.open
	('','','width=600,height=550,menubar=no,location=no,status=no,scrollbars=yes');

	
	SubWin.document.write('<html><head><meta http-equiv="content-type" content="text/html;charset=Shift_JIS"><title>');
	SubWin.document.write('入力内容確認フォーム');
	SubWin.document.write('</title><style type="text/css"><!--');
	SubWin.document.write('.normal { color: #333333; font-size: 12px; line-height: 140%; font-family: MSゴシック, osaka, Helvetica, Verdana }-->');
	SubWin.document.write('</style></head><body>');
	
	SubWin.document.write('	<table align="center" border="1" cellpadding="3" cellspacing="1" width="469">');
	SubWin.document.write('		<tr><td bgcolor="white" align="right" width="25%"><span class="normal">氏名</span></td>');
	SubWin.document.write('			<td bgcolor="white"><span class="normal">' + name1 + '</span></td></tr>');

	SubWin.document.write('		<tr><td bgcolor="white" align="right" width="25%"><span class="normal">性別</span></td>');
	SubWin.document.write('			<td bgcolor="white"><span class="normal">' + sex + '</span></td></tr>');

	SubWin.document.write('		<tr><td bgcolor="white" align="right" width="25%"><span class="normal">年齢</span></td>');
	SubWin.document.write('			<td bgcolor="white"><span class="normal">' + age + '</span></td></tr>');

	SubWin.document.write('		<tr><td bgcolor="white" align="right" width="25%"><span class="normal">住所</span></td>');
	SubWin.document.write('			<td bgcolor="white"><span class="normal">郵便番号　' + zip1 + '-' + zip2 + '<BR>住所　自宅　' + adr1 + '</span></td></tr>');

	SubWin.document.write('		<tr><td bgcolor="white" align="right" width="25%"><span class="normal">所属</span></td>');
	SubWin.document.write('			<td bgcolor="white"><span class="normal">会社名　' + cmp + '<BR>役職名　' + pst + '　勤続年数　' + wYr + '年<BR>郵便番号　' + zip3 + '-' + zip4 + '<BR>	住所　会社　' + adr2 + '</span></td></tr>');

	SubWin.document.write('		<tr><td bgcolor="white" align="right" width="25%"><span class="normal">連絡先</span></td>');
	SubWin.document.write('			<td bgcolor="white"><span class="normal">電話　・会社　　　' + tel1 + '<BR>電話　・自宅　　　' + tel2 + '<BR>FAX　・会社　　　' + fax1 + '<BR>FAX　・自宅　　　' + fax2 + '<BR>email・会社　　　' + eml1 + '<BR>email・自宅　　　' + eml2 + '</span></td></tr>');

	SubWin.document.write('		<tr><td bgcolor="white" align="right" width="25%"><span class="normal">受講希望講座</span></td>');
	SubWin.document.write('			<td bgcolor="white"><span class="normal">' + crs + '</span></td></tr>');

	SubWin.document.write('		<tr><td bgcolor="white" align="right" width="25%"><span class="normal">希望日</span></td>');
	SubWin.document.write('			<td bgcolor="white"><span class="normal">' + kDy + '</span></td></tr>');

	SubWin.document.write('		<tr><td bgcolor="white" align="right" width="25%" valign="top"><span class="normal">受講者</span></td>');
	SubWin.document.write('			<td bgcolor="white"><span class="normal">' + Memb + '</span></td></tr>');

	SubWin.document.write('		<tr><td bgcolor="white" align="right" width="25%"><span class="normal">宿泊あっせん希望</span></td>');
	SubWin.document.write('			<td bgcolor="white"><span class="normal">' + slp + '</span></td></tr>');
	SubWin.document.write('	</table><br>');

	SubWin.document.write('<div align="center"><Form><input type="button" value="上記確認の上送信します" OnClick="subm();"><br><br>');
	SubWin.document.write('<input type="button" value="戻る" OnClick="window.close();"></Form></div>');
	SubWin.document.write('</body></html>');


	SubWin.document.write('<script language=javascript>');
	SubWin.document.write('function subm(){');
	SubWin.document.write('	window.opener.document.eFormbishutc.submit();');
	SubWin.document.write('	window.close();');
	SubWin.document.write('}');
	SubWin.document.write('</script>');
		
	SubWin.document.close();

}

function func1(){
	if(win_closed(window.SubWin)){openWin()};
}


//--Child Window  OPEN or CLOSE 
function win_closed(winVar) {

  var ua = navigator.userAgent
  if( !!winVar )
      if( ( ua.indexOf('Gecko')!=-1 || ua.indexOf('MSIE 4')!=-1 )
           && ua.indexOf('Win')!=-1 ) 
           return winVar.closed
      else return typeof winVar.document  != 'object'
  else return true
}

function childclose(){
	if(win_closed(window.SubWin)){}else SubWin.close();
}
