function oWin(url,properties){ /*Properties = 'resizable=no,scrollbars=no, status=no, width=100,height=100, top=50, left=50'*/hurl = 'http://'+window.location.host+url;wwin = window.open( hurl, "logon", properties);wwin.focus();}function get_mouse(e){  if (!e) e = window.event;  if (e)  {     if (e.pageX || e.pageY)    { // this doesn't work on IE6!! (works on FF,Moz,Opera7)      x = e.pageX;      y = e.pageY;    }    else if (e.clientX || e.clientY)  {       x = e.clientX + document.body.scrollLeft;      y = e.clientY + document.body.scrollTop;    }    }//window.status = x + ' ' + y + ' ' + document.body.scrollTop;}function get_mouseclick(e){ if (!e) e = window.event;  if (e.button == 1){//	window.status="event2:"+event.type;}else {//window.status="event:"+event.type;}}function popkey(event){if (!event) event = window.event;           if (event.keyCode==27) {       helpScreen.display='none'      event.returnValue=false;    }    if ((event.keyCode == 8) && (event.srcElement.type != "text" && event.srcElement.type != "textarea" && event.srcElement.type != "password"))       {           event.returnValue=false       }        if (event.keyCode == 13)       {        	if (event.srcElement.name == 'query') {			sok();        	}   	           event.returnValue=false       }      }function sok() {        			var f = document.forms[0];				//var loc = thisDb + 'Search?SearchView&Query=' + f.query.value + '*&SearchOrder=4';				var loc = 'http://www.google.no/search?q='+f.query.value +' '+'site:'+location.host+thisDb;												//var comp = replacesubstring(loc, " ", "*+and+");				var comp = loc;												//alert(comp);				//self.location = comp;				wwin = window.open( loc, "logon",  'resizable=yes,scrollbars=yes, status=no, width=800,height=600, top=50, left=50');				return false;}function replaceCR(sourceList) {	for (var i=0; i<sourceList.length; i++) 		{ 			if (sourceList.charCodeAt(i) == 13) 					{ 						sourceList = sourceList.substring(0,i)+' '+sourceList.substring(i+1,sourceList.length)					} 								if (sourceList.charCodeAt(i) == 10) 					{ 						sourceList = sourceList.substring(0,i)+'<br>'+sourceList.substring(i+1,sourceList.length)					} 			} 		return sourceList}  function replacesubstring(sourceList,fromList,toList) {	for (var i=0; i<sourceList.length; i++) 		{ 		if (sourceList.substring(i,i+fromList.length) == fromList) 				{ 					sourceList = sourceList.substring(0,i)+toList+sourceList.substring(i+fromList.length,sourceList.length)				} 		} 	return sourceList}function navFylke(obj) {	var url = checkSelection(obj);	self.location = url;}function checkSelection( obj){	verdi = "";	for( j = 0; j < obj.length; j++	)	{		if( obj.options[j].selected == true)		{			verdi = obj.options[j].value;		}	}	return verdi}function imageOnClick(){	for( i=0; i<document.images.length ; i++ ) {		dis = document.images[i].src.toLowerCase();		if( dis.indexOf('$file') != -1 && dis.indexOf('reklame') == -1 && dis.indexOf('top.jpg') == -1 && dis.indexOf('mblad.gif') == -1) {			document.images[i].onclick= function() {  popUpMx('<center><img width=\"640\" border=0 src='+escape(this.src)+'>',220) };		}	}}function popUpMx(msg,ix){var content="<TABLE  WIDTH=330 BORDER=0 BORDERCOLOR=#000000 CELLPADDING=3 CELLSPACING=5 "+"BGCOLOR=#ffffff><TD ALIGN=left><FONT COLOR=black SIZE=2>"+unescape(msg)+"</FONT></TD><tr><td><center><input class=button_main type=Button value='Lukk vindu (esc)' onclick=\"helpScreen.display='none';\"></td></tr></TABLE>";helpScreen.left=ix+Xoffset;helpScreen.top=document.body.scrollTop+50;//alert(y/2 +document.body.scrollTop);document.getElementById("helpScreen").innerHTML=content;helpScreen.display='';}function popUpDiscussion(msg,ix,ref){var content="<TABLE  WIDTH=330 BORDER=0 BORDERCOLOR=#000000 CELLPADDING=3 CELLSPACING=5 "+"BGCOLOR=#ffffff><TD class=heading ALIGN=left>"+unescape(msg)+"</TD>"+"<tr><td class=ingress>Ditt navn:<br><input type=text name=av><br><br>"+"Skriv innlegget:<br><textarea rows=8 cols=60 name=innlegg></textarea><br><br>"+"<span class=\"mellomstorblaa\">Alle nye innlegg blir sendt til artikkelforfatter for godkjenning f\u00F8r de blir publisert.</span><br><br><input class=button_main type=Button value='Lagre innlegg'"+" onclick=\"if(document.forms[0].innlegg.value!='')"+"{self.location= thisDb+ 'wAdiscuss?Openagent&mail='+escape(document.forms[0].mailref.value)+'&noteid='+escape(document.forms[0].noteId.value)+'&ref="+ ref +"&av='+escape(document.forms[0].av.value)+'&innlegg='+escape(replaceCR(document.forms[0].innlegg.value));}\">"+"&nbsp;<input class=button_main type=Button value='Lukk vindu (esc)' onclick=\"helpScreen.display='none';\"></td></tr></TABLE>";helpScreen.left=ix+Xoffset;helpScreen.top=document.body.scrollTop+50;//helpScreen.top=50;document.getElementById("helpScreen").innerHTML=content;helpScreen.display='';}function popUpAbb(msg,ix){var content="<TABLE  WIDTH=330 BORDER=0 BORDERCOLOR=#000000 CELLPADDING=3 CELLSPACING=5 "+"BGCOLOR=#ffffff><TD class=heading ALIGN=left>"+unescape(msg)+"</TD>"+"<tr><td class=ingress>Din e-postadresse:<br><input type=text name=epost><br><br>"+"<span class=\"mellomstorblaa\">Du vil f\u00E5 en e-post n\u00E5r det er lagt ut nyheter.</span><br><br><input class=button_main type=Button value='Start abonnement'"+" onclick=\"if(document.forms[0].epost.value.match(/\\S+@([-\\w]+\\.)+\\w+/g) != null)"+"{self.location= thisDb + 'wAabb?Openagent&epost='+escape(document.forms[0].epost.value);}\">"+"&nbsp;<input class=button_main type=Button value='Lukk vindu (esc)' onclick=\"helpScreen.display='none';\"></td></tr></TABLE>";helpScreen.left=ix+Xoffset;helpScreen.top=250;document.getElementById("helpScreen").innerHTML=content;helpScreen.display='';}function popUp(msg){var content="<TABLE  WIDTH=330 BORDER=0 BORDERCOLOR=#000000 CELLPADDING=3 CELLSPACING=5 "+"BGCOLOR=#ffffff><TD ALIGN=left><FONT COLOR=black SIZE=2>"+unescape(msg)+"</TD><tr><td><center><input class=button_main type=Button value='Lukk vindu (esc)' onclick=\"helpScreen.display='none';\"></td></tr></TABLE>";x=300;y=220;helpScreen.left=x+Xoffset;helpScreen.top=y+Yoffset;helpScreen.top=document.body.scrollTop+50;document.getElementById("helpScreen").innerHTML=content;helpScreen.display='';}function popUpContact(msg,ix){var content="<TABLE  WIDTH=330 BORDER=0 BORDERCOLOR=#000000 CELLPADDING=3 CELLSPACING=5 "+"BGCOLOR=#ffffff><TD class=heading ALIGN=left>"+unescape(msg)+"</TD>"+"<tr><td class=ingress>Ditt navn:<br><input type=text name=av><br><br>"+"Din e-postadresse:<br><input type=text name=epost><br><br>Tekst:<br><textarea rows=8 cols=60 name=tekst></textarea><br><br>"+"<span class=\"mellomstorblaa\"></span><br><br><input class=button_main type=Button value='Send henvendelse'"+" onclick=\"if(document.forms[0].tekst.value!='')"+"{self.location= thisDb+ 'wAcontact?Openagent&av='+escape(document.forms[0].av.value)+'&fromepost='+escape(document.forms[0].epost.value)+'&tekst='+escape(replaceCR(document.forms[0].tekst.value));}\">"+"&nbsp;<input class=button_main type=Button value='Lukk vindu (esc)' onclick=\"helpScreen.display='none';\"></td></tr></TABLE>";helpScreen.left=ix+Xoffset;//helpScreen.top=document.body.scrollTop+50;helpScreen.top=50;document.getElementById("helpScreen").innerHTML=content;helpScreen.display='';}