function mainButton (name) {
    this.on = new Image();
    this.on.src = "/" + name + "_over.gif";
    this.off = new Image();
    this.off.src = "Images/" + name + ".gif";
}

function photoButton (name) {
    this.on = new Image();
    this.on.src = "Images/header_photo_" + name + "_on.gif";
    this.off = new Image();
    this.off.src = "Images/header_photo_" + name + "_off.gif";
}

function pageTitle (name) {
    this.on = new Image();
    this.on.src = "Images/page_title_" + name + "_over.gif";
    this.off = new Image();
    this.off.src = "Images/page_title_" + name + ".gif";
}

function mainButton_new (name) {
	mainButton[name] = new mainButton(name);
}

function photoButton_new (name) {
	photoButton[name] = new photoButton(name);
}

function pageTitle_new (name) {
	mainButton[name] = new pageTitle(name);
}

function show_mouseover (imgName) {
	document[imgName].src = mainButton[imgName].on.src;
}

function show_mouseout (imgName) {
	document[imgName].src = mainButton[imgName].off.src;
}

function show_mouseoverPhoto (imgName) {
	document[imgName].src = photoButton[imgName].on.src;
}

function show_mouseoutPhoto (imgName) {
	document[imgName].src = photoButton[imgName].off.src;
}

if (document.images != null) {
	mainButton_new('menu_home');
	mainButton_new('menu_company');
	mainButton_new('menu_portfolio');
	mainButton_new('menu_services');
	mainButton_new('menu_contact');
}