var path = "http://www.tsukuba.ac.jp/english/"; // Renewal 2007

/*------------------------------------------------------------------------------------------

	Begin Update [2008.07]

------------------------------------------------------------------------------------------*/

var code = new Array ();
var cache = new Array ();
var timerId = new Array ();

//Prospectus
code [0] = '<ul id="g_sub1" class="smtx">';
code [0] +=	'<li><a href="'+ path +'about/objective.html">Mission Statement</a></li>';
code [0] += '<li><a href="'+ path +'president/index.html">Office of the President</a></li>';
code [0] += '<li><a href="'+ path +'about/history.html">History</a></li>';
code [0] += '<li><a href="'+ path +'about/organization.html">Organizations</a></li>';
code [0] += '<li><a href="'+ path +'about/logomark.html">School Emblem</a></li>';
code [0] += '<li><a href="'+ path +'about/tsukuba.html">Tsukuba Science City</a></li>';
code [0] += '<li><a href="'+ path +'about/nobel/index.html">Nobel laureates</a></li>';
code [0] += '<li><a href="'+ path +'about/videoclip.html">Video Introduction</a></li>';
code [0] += '<li><a href="'+ path +'about/studentsong.html">Student Anthem</a></li>';
code [0] += '<li><a href="'+ path +'about/diamond.html">Tsukuba Diamond</a></li>';
code [0] += '<li><a href="'+ path +'about/kankyo/index.html">The University of Tsukuba’s Approach to Environment</a></li>';
code [0] += '<li><a href="http://www.geo-wlb.tsukuba.ac.jp/" target="_blank">*Office of Gender Equality</a></li>';
code [0] += '<li><a href="'+ path +'access/index.html">Access/Campus map</a></li>';
//code [0] += '<li><a href="'+ path +'about/campustour.html">Cyber Tour</a></li>';
code [0] += '</ul>';

//Admission
code [1] = '<ul id="g_sub2" class="smtx">';
code [1] += '<li><a href="'+ path +'admission/graduate.html">Graduate Admissions</a></li>';
code [1] += '<li><a href="'+ path +'admission/undergrad.html">Undergraduate Admissions</a></li>';
code [1] += '<li><a href="'+ path +'admission/classification.html">Student Classification</a></li>';

code [1] += '</ul>';

//Education
code [2] = '<ul id="g_sub3" class="smtx">';
code [2] += '<li><a href="'+ path +'organization/education.index.html">Educational Organizations</a></li>';
code [2] += '<li><a href="'+ path +'education/special-lectures-index.html">Special Lectures of the University of Tsukuba</a></li>';
code [2] += '<li><a href="'+ path +'education/calendar.html">Academic Calendar</a></li>';
code [2] += '<li><a href="'+ path +'education/challenged-support.html">Office for Students with Disabilities</a></li>';
code [2] += '<li><a href="'+ path +'education/programs/index.html">Distinctive Education and Research</a></li>';
//code [2] += '<li><a href="http://ocw.tsukuba.ac.jp/" target="_blank">* University of Tsukuba OpenCourseWare</a></li>';
code [2] += '</ul>';

//Campus Life
code [3] = '<ul id="g_sub4" class="smtx">';
code [3] += '<li><a href="'+ path +'campuslife/campus.html">Campus Facilities</a></li>';
code [3] += '<li><a href="'+ path +'campuslife/events.html">University Events</a></li>';
code [3] += '<li><a href="'+ path +'campuslife/studentplaza.html">Consultation service</a></li>';
code [3] += '<li><a href="'+ path +'campuslife/healthlife.html">Residence Halls/Apartment Information</a></li>';
code [3] += '<li><a href="'+ path +'campuslife/recreations.html">Training Facilities and Welfare Facilities</a></li>';
code [3] += '<li><a href="'+ path +'campuslife/supports.html">Organization/Extracurricular Activities for Students</a></li>';
code [3] += '<li><a href="'+ path +'campuslife/edu_healthlife.html">Tuition Reimbursement Program/Student Support</a></li>';
code [3] += '<li><a href="'+ path +'campuslife/part-time-jobs.html">Part-time Work for Students</a></li>';
code [3] += '<li><a href="'+ path +'campuslife/carshare.html">Car-Share Tsukuba</a></li>';
code [3] += '<li><a href="./public/magazines.html">*Publications for students</a></li>';
code [3] += '<li><a href="'+ path +'campuslife/aftercollege.html">Career Options after Graduation</a></li>';
code [3] += '<li><a href="'+ path +'campuslife/employment.html">Job Search Support System</a></li>';
code [3] += '</ul>';

//Research
code [4] = '<ul id="g_sub5" class="smtx">';
code [4] +='<li><a href="http://www.trios.tsukuba.ac.jp/scripts/websearch/index.htm" target="_blank">*The Tsukuba Researchers’ Information On-line System</a></li>';
code [4] += '<li><a href="http://www.osi.tsukuba.ac.jp/" target="_blank">*Organization for the Support and Development of Strategic Initiatives</a></li>';
code [4] += '<li><a href="'+ path +'research/g_coe.html">Global COE Program</a></li>';
code [4] += '<li><a href="http://wakate.biol.tsukuba.ac.jp/page015.html" target="_blank">*Initiative for the Promotion of Young Scientist’s Independent Reserarch-developing the next generation of leaders at the University of Tsukuba</a></li>';
code [4] += '<li><a href="http://edl.envr.tsukuba.ac.jp/eng/index.html" target="_blank">*Environmental Diplomatic Leader</a></li>';
code [4] += '<li><a href="'+ path +'research/21_coe.html">21st Century COE Program</a></li>';
code [4] += '<li><a href="'+ path +'research/fairness.html">Fair Promotion of Research Activities</a></li>';
code [4] += '<li><a href="'+ path +'research/liasons.html">University-Industry Cooperation</a></li>';
code [4] += '<li><a href="http://www.ilc.tsukuba.ac.jp/rehp/jp/hp/kigyo.htm" target="_blank">*Contact Address for Advice and Guidance</a></li>';
code [4] += '<li><a href="http://www.ilc.tsukuba.ac.jp/" target="_blank">*ILC (Tsukuba Industrial Liaison and Cooperative Research Center)</a></li>';
code [4] += '<li><a href="http://www.ilc.tsukuba.ac.jp/TLO/" target="_blank">*Tokyo Liaison Office, University of Tsukuba</a></li>';
code [4] += '<li><a href="'+ path +'research/notices.html">Information on Industry-University Cooperation</a></li>';
code [4] += '<li><a href="http://www.ilc.tsukuba.ac.jp/IPR/tsukubauni-ip.htm" target="_blank">*Intellectual property rights</a></li>';
code [4] += '<li><a href="http://www.ilc.tsukuba.ac.jp/COI/tsukubauni-coi.htm" target="_blank">*Management for Conflict of Interest</a></li>';
code [4] += '<li><a href="http://kjyo.sec.tsukuba.ac.jp/" target="_blank">*Research Subsidies</a></li>';
code [4] += '<li><a href="http://www.research-fund.sec.tsukuba.ac.jp/" target="_blank">*Competitive Funds and Open Grants Information</a></li>';
code [4] += '<li><a href="http://www.kokuren.tsukuba.ac.jp/gakujyutu.htm" target="_blank">*International exchange information</a></li>';
code [4] += '</ul>';

//Community
code [5] = '<ul id="g_sub6" class="smtx">';

code [5] += '<li><a href="'+ path +'community/contribution.html">Societal Contribution Project</a></li>';
code [5] += '<li><a href="http://www.sakura.cc.tsukuba.ac.jp/%7Eeeeforum/index.html" target="_blank">*Tsukuba Environment-Energy-Economy Forum(JP)</a></li>';
code [5] += '<li><a href="'+ path +'community/summer-schools.html">University of Tsukuba Summer Vacation Independent Research Otasuke-tai</a></li>';
code [5] += '<li><a href="'+ path +'community/extension.html">Extension Courses</a></li>';
code [5] += '<li><a href="'+ path +'seminar/index.html">Public Seminars</a></li>';
code [5] += '<li><a href="'+ path +'community/auditors.html">Credited Auditors</a></li>';
code [5] += '<li><a href="'+ path +'public/institutions/index.html">Spaces for Exhibition and Exchange</a></li>';
code [5] += '<li><a href="'+ path +'hall/index.html">University Hall Events</a></li>';
code [5] += '<li><a href="'+ path +'community/tsukuba_cafe/index.html">Cafes in the University of Tsukuba</a></li>';
code [5] += '<li><a href="'+ path +'community/kagakunome.html">"Buds of Science" Award</a></li>';

code [5] += '</ul>';

//International
code [6] = '<ul id="g_sub7" class="smtx">';
code [6] += '<li><a href="'+ path +'global/interaction.html">Academic Exchange Agreement</a></li>';
code [6] += '<li><a href="'+ path +'global/policy.html">Policy Papers on international cooperation</a></li>';
code [6] += '<li><a href="http://www.global.tsukuba.ac.jp/en/index_e.htm" target="_blank">*Global 30</a></li>';
code [6] += '<li><a href="'+ path +'global/overseas.html">Overseas Offices</a></li>';
code [6] += '<li><a href="https://www.ryudou.tsukuba.ac.jp/index.php?easiestml_lang=en" target="_blank">*University of Tsukuba Exchange Student Alumni Association</a></li>';
code [6] += '<li><a href="http://www.kokuren.tsukuba.ac.jp/index.htm" target="_blank">* International Liaison Office</a></li>';
code [6] += '<li><a href="http://www.intersc.tsukuba.ac.jp/" target="_blank">* International Student Center</a></li>';
code [6] += '</ul>';

function initSubNav () {
	for (i = 0; i < code.length; i ++) {
		var listNode = document.getElementById("list" + (i + 1));
		listNode.innerHTML = code [i];
	}
}

function showSubNav (n) {
	clearTimer (n);
	
	var navNode = document.getElementById("g_nav" + n);
	if (! cache [n - 1]) {
		cache [n - 1] = navNode.getAttribute ("src");
	}
	navNode.setAttribute("src", path + "common/images/g_nav" + n + "_o.gif");
	
	var listNode = document.getElementById("g_sub" + n);
	listNode.style.display = "block";
	listNode.style.zIndex = "100";
}

function hideSubNav (n) {
	var navNode = document.getElementById("g_nav" + n);
	navNode.setAttribute("src", cache [n - 1]);

	var listNode = document.getElementById("g_sub" + n);
	listNode.style.display = "none";
	listNode.style.zIndex = "0";
}

function setTimer (n) {
	timerId [n - 1] = setTimeout("hideSubNav(" + n + ")", 0);
}

function clearTimer (n) {
	clearTimeout (timerId [n - 1]);
}


/*------------------------------------------------------------------------------------------

	End Update [2008.07]

------------------------------------------------------------------------------------------*/




//initTopImage
function initTopImage (test){
	//更新の際は、下記変数を変更してください
	//画像キャプション
	var caption='<a href="./album/index.html">Campus Album <b>(Call for campus photos )</b></a>';	
	//var caption='<b>L\'Age d\'airain</b> (<a href="http://www.tsukuba.ac.jp/english/topimg_gallery/gallery.html">Previous photos can be viewed on the Image Gallery.)</a>';	
	
	//var caption='<a href="http://www.tsukuba-marathon.com/index.html" target="_blank">The 28th Tsukuba Marathon(2008.11.30)</a>';	
		
		
	//var caption='<a href="http://www.md.tsukuba.ac.jp/igakugun/exam/index.html" target="_blank">Admission by recommendation (School of Medicine, School of Medicine and Medical Sciences)(Application: November 4-7, 2008)</a>';	
	//var caption='<a href="" target="_blank">University Festival,  "Soho-Sai"(2008.10.11-13)</a>';	
	//var caption='<a href="http://www.tsukuba.ac.jp/english/admission/opencampus/index.html">Briefing Session for Prospective Students(2008.07.29-31)</a>';
	//var caption='"Nakamura Shinya, Miserere Ｘ VII 1999"';
	//var caption='<a href="http://www.stb.tsukuba.ac.jp/~yadokari/" target="_blank">Yadokari Festival(May 23-24,  2008)</a>';
	
	
	if(test == 'test'){         //トップページプレビュー
	document.write('<div id="mi_caption">'+caption+'</div>');
	}else{                      //トップページ
	document.write('<div id="mi_caption">'+caption+'</div>');
	}
}

//initTopTopics　トピックス
function initTopTopics (){
	document.write('<ul class="topicsList2 mtx">');
document.write('<li><a href="http://www.tsukuba.ac.jp/english/topics/20090907130716.html" style="color:#ff0000"><b>Measures Aginst the Influenza Type A (H1N1 etc.)</b></a></li>');
//document.write('<li><a href="http://www.tsukuba.ac.jp/english/admission/undergrad.html#global" style="color:#ff0000"><b>Call for Applications<br />Undergraduate Program <br />of International Social Studies 2010</b></a></li>');

//document.write('<li><a href="http://www.tsukuba.ac.jp/english/topics/20090721115314.html" style="color:#ff0000"><b>[Urgent Notice: To All University Students and Staff] </b></a></li>');


//document.write('<li><b><a href="http://www.tsukuba.ac.jp/english/event/20080703114803.html">Send-off Party for Beijing 2008 Olympic and Paralympic Games participants</b></a>（2008.07.08）</li>');
		
	//document.write('<li><a href="http://www.tsukuba.ac.jp/english/admission/opencampus/index.html">Briefing Session for Prospective Students for the Year 2008</a>(2008.07.29-31)</li>');
	
	//document.write('<li><a href="./education/special-lectures-2008.html">“Learning and University”, Special Lecture of the University of Tsukuba(broadcast)</a></li>');	
	
//document.write('<li><a href="http://www.tsukuba.ac.jp/english/topics/20071220163003.html"><b>The 1st Tsukuba 3E</b> (Environment Energy Economy)<b> Forum</b></a></li>');
//document.write('<li><strong><a href="http://ac.iit.tsukuba.ac.jp/ac/guide/setsumeikai/" target="_blank">Orientation Session for Applicants in 2008</a></strong></li>');
	
	
	document.write('</ul>');
}

//initTopHighlight ハイライト情報（トピックスの下の枠に表示されます。
function initTopHighlight (){

	//document.write('<img src="images/topics_line.gif" width="225" height="7" alt="" class="topicsHr" />');
	document.write('<ul class="topicsList2 mtx">');
	//document.write('<li><a href="../community/kagakunome/oubo.html" target="_blank">The 4th "Buds of Science" Award<img src="./common/images/mod__jp_icon.gif"></a></li>');
//document.write('<li><a href="http://ibo2009.org/top-J.html" target="_blank">International Biology Olympiad 2009 Tsukuba</a></li>');
//　document.write('<li><a href="http://www.dpipe.tsukuba.ac.jp/wbgsp/index.php" target="_blank">The Joint Japan/ World Bank Graduate Scholarship Program is currently accepting applications for its Eighth cohort</a></li>');
	//document.write('<li><a href="http://ibo2009.org/index_e.html"  target="_blank">The 20th International Biology Olympiad 2009</a></li>');

document.write('</ul>');
/**/
}

//initTopBnr バナーエリア（id="ul_banner"が画像バナー、id="txtbanner"がhtml記述用バナーです。
function initTopBnr (){
	document.write('<div id="ul_banner">');
	document.write('<ul>');
		//document.write('<li style="list-style:none"><a href="http://www.agbi.tsukuba.ac.jp/~agesd/index_e.html" target="_blank" title="2008 International Symposium on Agricultural Education for Sustainable Development"><img src="./images/ag-esd_e.gif" width="202" height="40" / alt="2008 International Symposium on Agricultural Education for Sustainable Development"></a></li>');

		//document.write('<li style="list-style:none"><a href="http://www.tsukuba.ac.jp/english/event/20090703133155.html" title="The Second Challenge for Physics Challenge 2009  "><img src="../images/phys2009.jpg" width="202" height="40" / alt="The Second Challenge for Physics Challenge 2009  "></a></li>');
	//document.write('<li style="list-style:none"><a href="http://ibo2009.org/index_e.html" target="_blank" title="The 20th International Biology Olympiad 2009"><img src="../images/ibo2009_b.gif" width="202" height="52" / alt="The 20th International Biology Olympiad 2009"></a></li>');
	//document.write('<li><a href="#"><img src="images/banner.gif" width="202" height="30" /></a></li>');
	document.write('</ul>');
	document.write('</div>');
	document.write('<div id="txtbanner">');
		//document.write('<div class="bnr"><span><a href="./event/20090604102643.html">Hirameki * Tokimeki Science</a></span></div>');
		document.write('<div class="bnr"><span><a href="./event/20091221111208.html">Special Lectures by Retiring Professors for 2009</a></span></div>');
//document.write('<div class="bnr"><span><a href="http://www.sakura.cc.tsukuba.ac.jp/~eeeforum/index.html" target="_blank">Tsukuba Environment-Energy-Economy Forum</a></span></div>');
	//document.write('<div class="bnr"><span><a href="http://www.stb.tsukuba.ac.jp/~shinkan/" target="_blank">University of Tsukuba New Students Welcome Festival</a></span></div>');
	document.write('<div class="bnr"><span><a href="organization/graduate.html">Graduate School</a></span></div>');
	document.write('<div class="bnr"><span><a href="organization/colleges.html">Schools and Colleges</a></span></div>');
	document.write('<div class="bnr"><span><a href="admission/graduate/opencampus.html">Open Campus for Graduate Schools</a></span></div>');

	document.write('</div>');
}

//initSubLink
function initSubLink(type){
	if(type == "all"){
		//subLink for Index
		document.write('<ul class="nav3">');
		document.write('<li><a href="'+path+'organization/"><img src="'+path+'common/images/lc_nav3_1.jpg" alt="Academic Organization" width="160" height="33" /></a></li>');
		document.write('<li><a href="'+path+'public/"><img src="'+path+'common/images/lc_nav3_2.jpg" alt="Public Relations" width="160" height="33" /></a></li>');
//		document.write('<li><a href="'+path+'activity/"><img src="'+path+'common/images/lc_nav3_3.jpg" alt="University Activities" width="160" height="33" /></a></li>');
		document.write('<li><a href="http://www.global.tsukuba.ac.jp/en/index_e.htm" target="_blank"><img src="'+path+'common/images/g30_banner_e2.jpg" alt="Global 30 " width="160" height="33" /></a></li>');
		document.write('<li><a href="'+path+'research/g_coe.html"><img src="'+path+'common/images/lc_nav3_4.jpg" alt="Global COE Program" width="160" height="33" /></a></li>');
		document.write('<li><a href="http://www.intersc.tsukuba.ac.jp/" target="_blank"><img src="'+path+'common/images/lc_nav3_5.jpg" alt="International Student Center" width="160" height="33" /></a></li>');
		document.write('</ul>');
		document.write('<ul class="nav4">');
//		document.write('<li><a href="'+path+'research/g_coe.html"><img src="'+path+'common/images/lc_nav4_1.gif" alt="Global COE Program" width="160" height="23" /></a></li>');
//		document.write('<li><a href="'+path+'research/21_coe.html"><img src="'+path+'common/images/lc_nav4_2.gif" alt="21st COE Program" width="160" height="23" /></a></li>');
		document.write('<li><a href="http://www.osi.tsukuba.ac.jp/" target="_blank"><img src="'+path+'common/images/lc_nav4_4.gif" alt="Organization for the Support and Development of Strategic Initiatives" width="160" height="23" /></a></li>');
		document.write('<li><a href="http://www.sakura.cc.tsukuba.ac.jp/~eeeforum/index.html" target="_blank"><img src="'+path+'common/images/lc_nav4_5.gif" alt="Tsukuba Enviroment-Energy-Economy Forum" width="160" height="23" /></a></li>');
		document.write('<li><a href="http://www.trios.tsukuba.ac.jp/scripts/websearch/index.htm?lang=en" target="_blank"><img src="'+path+'common/images/lc_nav4_3.gif" alt="Reserchers Search" width="160" height="23" /></a></li>');
		document.write('</ul>');
		document.write('<ul class="nav5 stx">');
		document.write('<li><a href="https://www.tulips.tsukuba.ac.jp/portal/index_eng.php" target="_blank"><strong>Library</strong><img src="'+path+'common/images/mod_bll_icon3.gif" height="9" width="9" border="0" alt="" style="padding-left:5px" /></a></li>');
		document.write('<li><a href="http://www.s.hosp.tsukuba.ac.jp/en/index-e.html" target="_blank"><strong>Hospital</strong><img src="'+path+'common/images/mod_bll_icon3.gif" height="9" width="9" border="0" alt="" style="padding-left:5px" /></a></li>');
		document.write('</ul>');
	}else{
		//subLink for Others
		// modified by K on 03/19/2007
		document.write('<ul class="nav3">');
		document.write('<li><a href="'+path+'organization/"><img src="'+path+'common/images/lc_nav3_1.jpg" alt="Academic Organization" width="160" height="33" /></a></li>');
		document.write('<li><a href="'+path+'public/"><img src="'+path+'common/images/lc_nav3_2.jpg" alt="Public Relations" width="160" height="33" /></a></li>');
//		document.write('<li><a href="'+path+'activity/"><img src="'+path+'common/images/lc_nav3_3.jpg" alt="University Activities" width="160" height="33" /></a></li>');
		document.write('<li><a href="http://www.global.tsukuba.ac.jp/en/index_e.htm" target="_blank"><img src="'+path+'common/images/g30_banner_e2.jpg" alt="Global 30 " width="160" height="33" /></a></li>');
document.write('<li><a href="'+path+'research/g_coe.html"><img src="'+path+'common/images/lc_nav3_4.jpg" alt="Global COE Program" width="160" height="33" /></a></li>');
		document.write('<li><a href="http://www.intersc.tsukuba.ac.jp/" target="_blank"><img src="'+path+'common/images/lc_nav3_5.jpg" alt="International Student Center" width="160" height="33" /></a></li>');
		document.write('</ul>');
		document.write('<ul class="nav4">');
//		document.write('<li><a href="'+path+'research/g_coe.html"><img src="'+path+'common/images/lc_nav4_1.gif" alt="Global COE Program" width="160" height="23" /></a></li>');
		//document.write('<li><a href="'+path+'research/21_coe.html"><img src="'+path+'common/images/lc_nav4_2.gif" alt="21st COE Program" width="160" height="23" /></a></li>');
		document.write('<li><a href="http://www.osi.tsukuba.ac.jp/" target="_blank"><img src="'+path+'common/images/lc_nav4_4.gif" alt="Organization for the Support and Development of Strategic Initiatives" width="160" height="23" /></a></li>');
		document.write('<li><a href="http://www.sakura.cc.tsukuba.ac.jp/~eeeforum/index.html" target="_blank"><img src="'+path+'common/images/lc_nav4_5.gif" alt="Tsukuba Enviroment-Energy-Economy Forum" width="160" height="23" /></a></li>');

		document.write('<li><a href="http://www.trios.tsukuba.ac.jp/scripts/websearch/index.htm?lang=en" target="_blank"><img src="'+path+'common/images/lc_nav4_3.gif" alt="Reserchers Search" width="160" height="23" /></a></li>');
		document.write('</ul>');
		document.write('<ul class="nav5 stx">');
		document.write('<li><a href="https://www.tulips.tsukuba.ac.jp/portal/index_eng.php" target="_blank"><strong>Library</strong><img src="'+path+'common/images/mod_bll_icon3.gif" height="9" width="9" border="0" alt="" /></a></li>');
		document.write('<li><a href="http://www.s.hosp.tsukuba.ac.jp/en/index-e.html" target="_blank"><strong>Hospital</strong><img src="'+path+'common/images/mod_bll_icon3.gif" height="9" width="9" border="0" alt="" /></a></li>');
		document.write('</ul>');
	}
}



//initButton
function initButton() {
	if(navigator.appVersion.indexOf("Mac") > -1 && navigator.appName.charAt(0) == "M"){
		//MacIE
  	}else{
		document.write('<a href="#" onclick="replace_css(\'print\',\''+path+'common/css/print.css\');window.print();changeCSS()">');
		document.write('<img src="'+path+'common/images/ct_nav_print.gif" alt="本文印刷" width="83" height="24" border="0" />');
		document.write('</a>');
	}
}





//左メニュー

function LeftMenuOn(id) {

if(id){
var isIE = (document.documentElement.getAttribute("style") == document.documentElement.style);
document.getElementById(id).setAttribute("class","on");
if(isIE){
document.getElementById(id).setAttribute("className","on");
}
}

}



//このページのトップへ
var Mac = navigator.appVersion.indexOf('Mac',0) != -1;
var Win = navigator.appVersion.indexOf('Win',0) != -1;
var IE  = navigator.appName.indexOf("Microsoft Internet Explorer",0) != -1;
var NN  = navigator.appName.indexOf("Netscape",0) != -1;
var Moz = navigator.userAgent.indexOf("Gecko") != -1;
var Vmajor = parseInt(navigator.appVersion);	// ex. 3
var Vminor = parseFloat(navigator.appVersion);	// ex. 3.01
var MacIE4 = ((Mac && navigator.appVersion.indexOf('MSIE 4.',0) != -1));
var MacIE3 = ((Mac && navigator.appVersion.indexOf('MSIE 3.',0) != -1));

function getScrollLeft() {
	if ((navigator.appName.indexOf("Microsoft Internet Explorer",0) != -1)) {
		if(navigator.appVersion.indexOf("Mac") > -1){
			return document.body.scrollLeft;
  		}else{
			return document.documentElement.scrollLeft;
		}
	} else if (window.pageXOffset) {
		return window.pageXOffset;
	}else{
		return 0;
	}
}

function getScrollTop() {
	if ((navigator.appName.indexOf("Microsoft Internet Explorer",0) != -1)) {
		if(navigator.appVersion.indexOf("Mac") > -1){
			return document.body.scrollTop;
  		}else{
			return document.documentElement.scrollTop;
		}
	} else if (window.pageYOffset) {
		return window.pageYOffset;
	} else {
		return 0;
	}
}

function getScrollWidth() {
	if ((navigator.appName.indexOf("Microsoft Internet Explorer",0) != -1)) {
		if(navigator.appVersion.indexOf("Mac") > -1){
			return document.body.scrollWidth;
  		}else{
			return document.documentElement.scrollWidth;
		}
	} else if (window.innerWidth) {
		return window.innerWidth;
	}
	return 0;
}

function getScrollHeight() {
	if ((navigator.appName.indexOf("Microsoft Internet Explorer",0) != -1)) {
		if(navigator.appVersion.indexOf("Mac") > -1){
			return document.body.scrollHeight;
  		}else{
			return document.documentElement.scrollHeight;
		}
	} else if (window.innerHeight) {
		return window.innerHeight;
	}
	return 0;
}

var pageScrollTimer;

function pageScroll(toX,toY,frms,cuX,cuY) {
 if (pageScrollTimer) clearTimeout(pageScrollTimer);
 if (!toX || toX < 0) toX = 0;
 if (!toY || toY < 0) toY = 0;
 if (!cuX) cuX = 0 + getScrollLeft();
 if (!cuY) cuY = 0 + getScrollTop();
 if (!frms) frms = 6;

 cuX += (toX - getScrollLeft()) / frms; if (cuX < 0) cuX = 0;
 cuY += (toY - getScrollTop()) / frms;  if (cuY < 0) cuY = 0;
 var posX = Math.floor(cuX);
 var posY = Math.floor(cuY);
 window.scrollTo(posX, posY);
 if (posX != toX || posY != toY) {
  pageScrollTimer = setTimeout("pageScroll("+toX+","+toY+","+frms+","+cuX+","+cuY+")",16);
 }
}

function toTop(){
	if (!MacIE3 && !MacIE4 && !NN && window.scrollTo || NN && (Vminor >= 4.75) && window.scrollTo) {
		pageScroll(0,0,6);
	} else {
		location.hash = "pageTop";
	}
}

//ポップアップ
function popup(url) {
	newWin = window.open(url,'popped',
	'width=550,height=450,toolbar=no,border=0,status=no')
	newWin.focus()
}