/* function Imageover
------------------------------------------------------------------------------------------------- */
var Imageover = function() {
	this.initImagesOver = function() {
		if(document.getElementsByTagName) {
			var images = document.getElementsByTagName('img');
			var input = document.getElementsByTagName('input');

			var imgOn = new Array();
			var inputOn = new Array();

			for (var i=0; i < images.length; i++) {
				if(images[i].className == 'noover') {
					continue;
				}

				if (images[i].src.match(/(.*_)off(\..*)$/)) {
					imgOn[i] = new Image();
					imgOn[i].src = RegExp.$1 + 'on' + RegExp.$2;

					images[i].onmouseover = function() {
						this.setAttribute('src', this.src.replace('_off.', '_on.'));
					}
					images[i].onmouseout = function() {
						this.setAttribute('src', this.src.replace('_on.', '_off.'));
					}
				}
			}

			for (var i=0; i < input.length; i++) {
				if(input[i].className == 'noover') {
					continue;
				}

				if (input[i].src.match(/(.*_)off(\..*)$/)) {
					inputOn[i] = new Image();
					inputOn[i].src = RegExp.$1 + 'on' + RegExp.$2;

					input[i].onmouseover = function() {
						this.setAttribute('src', this.src.replace('_off.', '_on.'));
					}
					input[i].onmouseout = function() {
						this.setAttribute('src', this.src.replace('_on.', '_off.'));
					}
				}
			}

		}
	}


	// イベントを追加する関数
	this.addEvent = function(eventTarget, eventName, func) {
		// モダンブラウザ
		if(eventTarget.addEventListener) {
			eventTarget.addEventListener(eventName, func, false);
		}
		// IE
		else if(window.attachEvent) {
			eventTarget.attachEvent('on'+eventName, function(){func.apply(eventTarget);});
		}
	}

	this.load = function() {
		var self = this;
		this.addEvent(window,"load",function(){self.initImagesOver();});
	}
};
var Imageover = new Imageover();
Imageover.addEvent(window,"load",function(){Imageover.initImagesOver();});


/* function tr:even find
------------------------------------------------------------------------------------------------- */
$(document).ready(function(){
	$('.table01').each(function(){
		$(this).find('tr:even').addClass('even');
	});
});
