jQuery(function($) {
			$('#menu > li > span.title').data('bln',false);
			
            $('#menu > li > span.title').click(function(){
				if(!$(this).data('bln'))
				{
					$('#menu > li').each(function(){
						if($(this).children('.title').data('bln')){
							slide_down($(this).children('.title'))
						}
					});
					slide_up($(this))
				}
				else{slide_down($(this))}

			});
			
			function slide_up($this)
			{
				$($this).parent().stop(true,true).animate({'bottom':'0px'}, 300);
				$($this).toggleClass('titleactive');
				$($this).data('bln',true);
				$('#middle_content').toggleClass('deactive_layer');
				$('.column1_home > .container').css('z-index','102');
			}
			
			function slide_down($this)
			{
				$($this).parent().stop(true,true).animate({'bottom':'-334px'}, 300);
				$($this).toggleClass('titleactive');
				$($this).data('bln',false);
				$('#middle_content').toggleClass('deactive_layer');
				$('.column1_home > .container').css('z-index','100');
			}
        });

// JavaScript Document

// email to a friend
function EmailLink(){
window.location = "mailto:"+"?subject=CompuGROUP - Synchronizing the world of healthcare" + "&body=" + "I thought this link might interest you:  " + document.title + "  " + location.href;
}

// bookmark function
function Bookmark()
{
	  // Get title
	  title = window.document.title;
	  // Get url
	  url = window.document.location;

	  if ((navigator.appName == "Microsoft Internet Explorer") && (parseInt(navigator.appVersion) >= 4))
	  window.external.AddFavorite(url, title);
	  else
	  alert("Press CTRL-D (Firefox) or COMMAND-D(Safari) to bookmark this page");
}

var popbackground="white" //specify backcolor or background image for pop window
var windowtitle="Image Window"  //pop window title

function detectexist(obj){
return (typeof obj !="undefined")
}

function jkpopimage(imgpath, popwidth, popheight, textdescription){

function getpos(){
leftpos=(detectexist(window.screenLeft))? screenLeft+document.body.clientWidth/2-popwidth/2 : detectexist(window.screenX)? screenX+innerWidth/2-popwidth/2 : 0
toppos=(detectexist(window.screenTop))? screenTop+document.body.clientHeight/2-popheight/2 : detectexist(window.screenY)? screenY+innerHeight/2-popheight/2 : 0
if (window.opera){
leftpos-=screenLeft
toppos-=screenTop
}
}

getpos()
var winattributes='width='+popwidth+',height='+popheight+',resizable=yes,left='+leftpos+',top='+toppos
var bodyattribute=(popbackground.indexOf(".")!=-1)? 'background="'+popbackground+'"' : 'bgcolor="'+popbackground+'"'
if (typeof jkpopwin=="undefined" || jkpopwin.closed)
jkpopwin=window.open("","",winattributes)
else{
//getpos() //uncomment these 2 lines if you wish subsequent popups to be centered too
//jkpopwin.moveTo(leftpos, toppos)
jkpopwin.resizeTo(popwidth, popheight+30)
}
jkpopwin.document.open()
jkpopwin.document.write('<html><body '+bodyattribute+'><img src="'+imgpath+'" style="margin-bottom: 0.5em"></body></html>')
jkpopwin.document.close()
jkpopwin.focus()
}

