$(function () {
	
	
	
	
	$(".accordion div.menu1").click(function(){
		$(this).next("div.menu2").slideToggle("slow", function(){			 
			if ($.browser.msie == true &&  $.browser.version == '6.0'){
			
				if ($(this).css('display') == 'block'){
					$('.overlay', this).css({height:  $('ul', this).height() + 12 + 'px'});
				} else {
					$('.overlay', this).css({height:'0px'});
				}				
			}			
		}).siblings("div.menu2:visible").slideUp("slow");
		$(this).toggleClass("active");
		$(this).siblings("div.menu1").removeClass("active");
	});
	
	if($('table').length) {
        $('table').find('tr:odd').addClass('hilight');
    }
});

function activatemenu(id){
	$(".accordion div#l1_"+id).addClass("active");
	if ($.browser.msie == true &&  $.browser.version == '6.0'){
		obj = $(".accordion div#l2_"+id);
		$('.overlay', obj).css({height:  $('ul', obj).height() + 12 + 'px'});
	}	
	$(".accordion div.menu2:not(#l2_"+id+")").hide();
}

// =fixing png for IE. now you should only add class "png" to show the transparent *.png image in IE6
function PNG(element){
	if (/MSIE (5\.5|6).+Win/.test(navigator.userAgent)){
	var src;
	if (element.tagName=='IMG'){
			if (/\.png$/.test(element.src)){
				src = element.src;
				element.src = "images/t.gif"; // = 1*1px  transparent image and path for it
			}
		}
		else {
			src = element.currentStyle.backgroundImage.match(/url\("(.+\.png)"\)/i)
			if(src){
				src = src[1];
				element.runtimeStyle.backgroundImage="none";
			}
		}
	if (src) element.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + src + "',sizingMethod='scale')";
	}
}