﻿// JavaScript Document
window.onload = tabEffect;
function tabEffect()
{
	var allElements = document.getElementsByTagName('*');
	for (var i=0; i<allElements.length; i++)
	{
		if (allElements[i].className.indexOf('tabOption') >= 0)
		{
			allElements[i].onclick = onclick;
		}
	}
}
function onclick()
{
    tabList = this.parentNode;
    tabOptions = tabList.getElementsByTagName("li");
	for (var i=0; i<tabOptions.length; i++)
	{
	    if (tabOptions[i].className.indexOf('tabOption') >= 0)
		{
		    tabOptions[i].className = "tabOption";
		}
	}
	this.className += " current";
}
function show(objectid){
   var objdiv=document.getElementById(objectid);
   objdiv.className = "current inside box";
}
function hide(objectid){
	var objdiv = document.getElementById(objectid);
	objdiv.className = "inside box";
}
function show2(objectid){
   var objdiv=document.getElementById(objectid);
   objdiv.className = "current";
}
function hide2(objectid){
	var objdiv = document.getElementById(objectid);
	objdiv.className = "";
}
function show3(objectid){
	var objdiv = document.getElementById(objectid);
	objdiv.style.display = "block";
}
function hide3(objectid){
	var objdiv = document.getElementById(objectid);
	objdiv.style.display = "none";
}
function addfavorite()
{
   if (document.all)
   {
      window.external.addFavorite('http://www.ykpass.com/','医学考试在线');
   }
   else if (window.sidebar)
   {
      window.sidebar.addPanel('医学考试在线','http://www.ykpass.com/',"");
   }
}
function chatWindow() {
	window.open("http://www.918kf.com/client.aspx?worker_id=748844", "", "height=473, width=703, toolbar=no, menubar=no, scrollbars=no, resizable=no,location=no, status=no");
}
