function menu_top_on() {
	document.getElementById('menu_1').innerHTML = '<img src="img/menu_1_on.gif" width="19" height="19" alt="" />';
}
function menu_top() {
	document.getElementById('menu_1').innerHTML = '<img src="img/menu_1.gif" width="19" height="19" alt="" />';
}
function menu_on(div) {
	document.getElementById(div).innerHTML = '<img src="img/menu_on.gif" width="19" height="19" alt="" />';
}
function menu(div) {
	document.getElementById(div).innerHTML = '<img src="img/menu.gif" width="19" height="19" alt="" />';
}

function marquee() {
if(document.getElementById('marquee')) {
	var speed = 1;
	var time = 20;
	if(document.all) time = 15;
	var element_width = document.getElementById('marquee').offsetWidth;
	var text = document.getElementById('in_marquee').innerHTML;
	document.getElementById('in_marquee').innerHTML = '<span id="temp" style="position:absolute; top:-1000px; left:-9000px; visibility: hidden;">'+text+'</span>';
	var text_width = document.getElementById('temp').offsetWidth;
	document.getElementById('in_marquee').style.width = text_width + 'px';
	document.getElementById('in_marquee').innerHTML = text;
	document.getElementById('in_marquee').style.left = element_width + 'px';
	move = setInterval( function() {
		if((document.getElementById('in_marquee').offsetLeft + text_width) < 0) document.getElementById('in_marquee').style.left = element_width + 'px';
		document.getElementById('in_marquee').style.left = document.getElementById('in_marquee').offsetLeft - speed + 'px';
		}, time)
	document.getElementById('in_marquee').onmousemove = function() { clearInterval(move); }
	document.getElementById('in_marquee').onmouseout = function() {
		move = setInterval( function() {
			if((document.getElementById('in_marquee').offsetLeft + text_width) < 0) document.getElementById('in_marquee').style.left = element_width + 'px';
			document.getElementById('in_marquee').style.left = document.getElementById('in_marquee').offsetLeft - speed + 'px';
			}, time)
		}
	}
}


window.addLoadEvent = function(func) {
var oldonload = window.onload;
if (typeof window.onload != 'function') {
	window.onload = func;
	}
else {
	window.onload = function() {
		if (oldonload) {
			oldonload();
			}
		func();
		}
	}
}
window.addLoadEvent(function() { marquee(); });