var dom=document.getElementById;var identity = new Array(4);identity[0]= char(64) + "Im" + char(97) + "g" + char(101) + "n-Bi" + char(111) + "t" + char(101) + char(99) + "h." + char(99) + char(111) + "m";identity[1]= char(73) + "nfo";identity[2]="R" + char(111) + "d.B" + char(101) + "ns" + char(111) + "n";identity[3]="G" + char(97) + "r" + char(101) + "th.Griffiths";function char(pNum){	return String.fromCharCode(pNum);}
function scrollscroller(){	if (ObjScrollFlag.innerHTML=="false" && parseInt(ObjScroll.style.top)==-480) return;	if (parseInt(ObjScroll.style.top)>-580) 		ObjScroll.style.top=parseInt(ObjScroll.style.top)-ScrollerSpeed+"px"; 	else{ 		ObjScroll.style.top="153px";	}}
function pause(){	ScrollerSpeed=0;}
function play(){	ScrollerSpeed=ScrollerSpeedMem;}
function ChangeMenu(pLink){	if (!dom) return; //not modern browser then do not execute script	OldObj=(ObjMenuPos.innerHTML!="") ? document.getElementById(ObjMenuPos.innerHTML) : false; 	OldAssayObj=(ObjSubMenuPos.innerHTML!="") ? document.getElementById(ObjSubMenuPos.innerHTML) : false;	NewObj=document.getElementById(pLink);	if (pLink!="AssayList") ChangeSelection(OldObj, NewObj)	document.getElementById("AssayList").style.display="none";	if (NewObj.id=="Home" || NewObj.id=="Videos"){		document.getElementById("ScrollParent").style.display="none";		document.getElementById("BoxMenu").style.display="none";		document.getElementById("html").style.backgroundColor="black";	}	else if (NewObj.id=="Quote"){		document.getElementById("ScrollParent").style.display="none";		document.getElementById("BoxMenu").style.display="none";		document.getElementById("html").style.backgroundColor="#606060";	}		else{		if (NewObj.id=="Company" && document.getElementById("ScrollParent").style.display=="none") ObjScroll.style.top="153px";		document.getElementById("ScrollParent").style.backgroundColor="#E0E0E0";		document.getElementById("ScrollParent").style.display="block";		document.getElementById("ScrollParent").style.width="151px";		document.getElementById("BoxMenu").style.display="block";		document.getElementById("BoxMenu").style.width="153px";		document.getElementById("BoxMenu").style.backgroundImage="url('img/Submenu.png')";		document.getElementById("BoxMenuSub").style.width="151px";		document.getElementById("html").style.backgroundColor="#606060";		document.getElementById("BoxMenuSub").style.backgroundColor="white";		ObjScrollFlag.innerHTML=(NewObj.id=="Company") ? "true" : "false";	}	if (NewObj.id!="Assays" && OldAssayObj){		a=document.getElementById("BoxMenu");		a.style.color="black";		ChangeSelection(OldAssayObj);		ObjSubMenuPos.innerHTML="";	}	if (pLink!="AssayList") ObjMenuPos.innerHTML=pLink;}
function ChangeAssayMenu(pLink){	OldObj=(ObjMenuPos.innerHTML!="") ? document.getElementById(ObjMenuPos.innerHTML) : false; 	OldAssayObj=(ObjSubMenuPos.innerHTML!="") ? document.getElementById(ObjSubMenuPos.innerHTML) : false;	NewAssayObj=document.getElementById(pLink);	if (pLink!="AssayList"){		if (OldObj.id!="Assays") ChangeMenu("Assays");		document.getElementById("ScrollFlag").innerHTML="false";		document.getElementById("ScrollParent").style.display="block";		document.getElementById("ScrollParent").style.backgroundColor="#E0E0E0";		document.getElementById("ScrollParent").style.width="163px";		document.getElementById("BoxMenu").style.display="block";		document.getElementById("BoxMenu").style.width="165px";		document.getElementById("BoxMenu").style.backgroundImage="url('img/SubmenuWide.png')";		document.getElementById("html").style.backgroundColor="black";		document.getElementById("BoxMenuSub").style.backgroundColor="#E0E0E0";		document.getElementById("BoxMenuSub").style.width="163px";		document.getElementById("AssayList").style.display="block";		ObjScrollFlag.innerHTML="false";		ObjScroll.style.top="-480px";		a=document.getElementById("BoxMenu");		a.style.color="#e40059";		ChangeSelection(OldAssayObj, NewAssayObj);		ObjSubMenuPos.innerHTML=pLink;	}	else{		ChangeMenu("AssayList");	}}function StopScroll(){	window.top.document.getElementById("ScrollFlag").innerHTML="false";}
function ChangeSelection(pOld, pNew){	var label, objImage;	if (pOld){		if (pOld.id=="Videos" || pOld.id=="Quote"){			objImage=findchild(pOld,"IMG");			pOld.removeChild(objImage);		}		else{			a=findchild(pOld,"#text");			a.nodeValue="";		}		a=findchild(pOld,"A");		a.style.display="inline";	}	if (pNew){		a=findchild(pNew,"A");		label=a.innerHTML;		a.style.display="none";		if (pNew.id=="Videos" || pNew.id=="Quote"){			objImage=document.createElement("img");			objImage.style.border="none";			if (pNew.id=="Videos"){				objImage.style.marginLeft="-1px";				objImage.src="img/Videos2.png";			}			else{				objImage.src="img/Email2.png";			}			pNew.appendChild(objImage);		}		else{			a=findchild(pNew,"#text");			if (a)				a.nodeValue=label;			else{				var TextNode=document.createTextNode(label);				pNew.appendChild(TextNode);			}		}	}}
function findchild(obj,tag){	cn=obj.childNodes;	for (k=0; k<cn.length; k++){		if (cn[k].nodeName==tag) return cn[k];	}	return false;}if (dom){ //if not modern dom based browser then do not execute any Java Script	var ScrollerSpeed=1;	ScrollerSpeed=(document.all) ? ScrollerSpeed : Math.max(1, ScrollerSpeed-1);	var ScrollerSpeedMem=ScrollerSpeed;	var ObjScroll=document.getElementById("Scroll");	var ObjScrollFlag=document.getElementById("ScrollFlag");	var ObjMenuPos=document.getElementById("MenuPos");	var ObjSubMenuPos=document.getElementById("SubMenuPos");	var Announcement = new Array(10);	Announcement[0]="<h4>Announcements</h4>";	Announcement[1]="<p>Successfully raised 400K to invest in the state-of-the-art High Content Analysis <a href='Equipment.html' onclick=" + char(34) + "ChangeMenu('Company');" + char(34) + "target='BodyFrame'>equipment  and robotics.</a></p>";	Announcement[2]="<p>Part of a consortium on a EU Framework 7 award: Rheumatoid arthritis and periodontal inflammatory disease.</p>";	Announcement[3]="<p>Awarded BBSRC Case award with Dr Eustace Johnson from Aston University to develop phenotypic screening assays for mesenchymal stem cells.</p>";	Announcement[4]="<p>Awarded BBSRC interchange grant with the institute of science and technology (RJAH) orthopaedic hospital: High Content Biology to assess the angiogenic and neurogenic potential of mesenchymal stem cells with relevance to tissue repair.</p>"	Announcement[5]="<p>New to High Content Analysis? Why not use our <a href='Consultancy.html' onclick=" + char(34) + "ChangeMenu('Company');" + char(34) + "target='BodyFrame'>free report service</a>.</p>";	Announcement[6]="<p>For all your screening needs</p>";	Announcement[7]="<p style='font-size:9pt'><a href='m" + char(97) + "ilt" + char(111) + ":" + identity[1] + identity[0] + "'>" + identity[1] + identity[0] + "</a><br/><br/>+44 161 606-7380</p>"	for (k=0; k<8; k++){		ObjScroll.innerHTML=ObjScroll.innerHTML + Announcement[k];	}	ObjScroll.style.top="153px";	ObjScroll.onmouseover=pause;	ObjScroll.onmouseout=play;	ChangeMenu("Home");	lefttime=setInterval("scrollscroller()",40);	if (location.search){		if (location.search.indexOf("AssayExamples")>0){			document.getElementById("BodyFrame").src= "AssayExamples" + location.search.substr(location.search.lastIndexOf("/"));			ChangeAssayMenu(location.search.substring(location.search.lastIndexOf("/")+1,location.search.length-5));		}		else if (location.search.indexOf("Christmas")>0){			document.getElementById("BodyFrame").src= "Christmas" + location.search.substr(location.search.lastIndexOf("/"));			ChangeAssayMenu(location.search.substring(location.search.lastIndexOf("/")+1,location.search.length-5));		}		else {			document.getElementById("BodyFrame").src=location.search.substr(location.search.lastIndexOf("/")+1);				}		if (location.hash.substr(1)!="Home") ChangeMenu(location.hash.substr(1));	}}
