//------------------------------------------
//	jquery RollOver用
//	オーバー画像には_on.gifにする。
//	$(".over").RollOver();
//------------------------------------------

$.fn.RollOver = function()
{
	$(this).hover(function(){
		mouseOver($(this));
	},function(){
		mouseOut($(this));
	});
	
	_preload($(this));
	
	function mouseOver (el)
	{
		$(el).attr("src",$(el).attr("src").replace(".gif", "_on.gif"));
	}
	
	function mouseOut (el)
	{
		$(el).attr("src",$(el).attr("src").replace("_on.gif", ".gif"));
	}
	
	function _preload (el)
	{
		var preLoadImg = new Image();
		preLoadImg.src = $(el).attr("src").replace(".gif", "_on.gif");
	}
}

//----------------------------------------
//	プルダウンメニュー
//	読込み例)
//	$("#globalMenu dt").PullDownMenu();
//----------------------------------------

$.fn.PullDownMenu = function()
{
	$(this).bind('mouseover',function(){
		if($(this).children("img")){
			$(this).children("img").attr("src",$(this).children("img").attr("src").replace(".gif", "_on.gif"));
		}
		$(this).find(".menuChild").show();
	});
	
	$(this).bind('mouseout',function(){
		if($(this).children("img")){
			$(this).children("img").attr("src",$(this).children("img").attr("src").replace("_on.gif", ".gif"));
		}
		$(this).find(".menuChild").hide();
	});

}

// 登録情報用
$.fn.Register = function()
{
	$(this).each(function()
	{
		$(this).bind('click',function()
		{
			if($('input[@name=job][@value=student]').attr("checked"))
			{
				$(".student").show();
			}else{
				$(".student").hide();
			}
			return true;
		});
	});
}

//別窓
function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}