var menu = Class.create();

menu.prototype = {

	hrefOne: '',
	prevIm: '',
	
	initialize: function() {
		this.setEvents();
	},
	
	setEvents: function() {
		var self = this;
	
		this.hrefOne = $A($$('.for_menu'));
		
		this.hrefOne.each(function(img) {
			
			img.onmouseover = function() {
				self.repl_to_active(img);
			}
			
			img.onmouseout = function() { 
				self.repl_to_normal(img);
			}
								
		});
	},
	
	repl_to_active: function(img) {
		this.prevIm = img.src;
		img.src = img.readAttribute('rollover');
	},
	
	repl_to_normal: function(img) {
		img.src = this.prevIm;
	}
}


Event.observe(window, 'load', function() {
	new menu;
});
