function changeBgcolor(){
	var dstyleA = document.getElementById('navmenu').style;
	var dstyleB = document.getElementById('menuhead').style;
	var colornom = getColor();
	var headimg = getBgimg();
	dstyleA.background = colornom + ' repeat url(images/bg-menu2.gif)';
	dstyleB.background = 'white repeat-x url(' + headimg + ')';
}
function getColor(){
	var colorList = new Array('#ffffff','#E8F7FF','#FEFFE9','#FFF8E8','#E9EFFF');
	var r = Math.floor(Math.random()*colorList.length);
	return colorList[r];
}
function getBgimg(){
	var bgList = new Array('bg-menuhead.png','bg-menuhead4.png','bg-menuhead2.png','bg-menuhead3.png','bg-menuhead.png','bg-menuhead3.png','bg-menuhead4.png');
	var r = Math.floor(Math.random()*777) % bgList.length;
	var bgimg = 'images/' + bgList[r];
	return bgimg;
}
function forIeOld(on){
	if(isieold){
		if(on) document.getElementById('menuhead').style.background = 'white repeat-x url(images/bg-menuhead5.png)';
		else{
			var headimg = getBgimg();
			document.getElementById('menuhead').style.background = 'white repeat-x url(' + headimg + ')';
		}
	}
}
var isieold = false;
brouserCheck();
function brouserCheck(){
	var ua = navigator.userAgent;
	var v = parseInt(navigator.appVersion);
	if(document.all && ua.indexOf('MSIE')>0 ) {
		isie = true;
		if(v < 7) isieold = true;
	}
}

