function RefreshWnd(wnd)
{
	if (wnd && wnd.location) 
	{
		strLoc=opener.location.href
		intPos=strLoc.indexOf("&rnd=") + strLoc.indexOf("?rnd=") + 1
		if (intPos>=0)
		{
			intPos1=strLoc.indexOf("&",intPos+1)
			strLocNew=strLoc.substring(0,intPos) + RndSign(strLoc.substring(0,intPos)) + "rnd=" + parseInt(Math.random()*1000000)
			if (intPos1>=0) strLocNew=strLocNew + strLoc.substring(intPos1,strLoc.length)
		}
		else
			strLocNew=strLoc + RndSign(strLoc) + 'rnd=' + parseInt(Math.random()*1000000)
		wnd.location.replace (strLocNew)

	}
}
function RndSign(str)
{
	if (str.indexOf('?')>=0) return '&'
	else return '?'
}
function NewWindow(mypage, myname, w, h, scroll,loc,res){
if (!loc) loc='yes'
if (!res) loc='no'
var winl = (screen.width - w) / 2;
var wint = (screen.height - h) / 2 - 100;
winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars='+scroll+',resizable='+res+',toolbar=no,status=no,menubar=no,location='+loc
win = window.open(mypage, myname, winprops)
}
function Browser(did, squery, from)
{
	if (from) from='&k1=' + from
	else from=''
	NewWindow('browser.asp?did='+did+squery+from,'br'+ parseInt(Math.random()*1000),screen.width*0.65,screen.height*0.65,'yes','no','yes')
}
function Ldr(img) {var objImg=new Image(); objImg.src=img; return objImg;}
function hmn(img) {return(Ldr('img/icons/'+img));}
function over(a,s){document[a].src=eval(a+s+'.src');}

function GetFile(id, from)
{
	if (from) sAdd='&from=' + from
	else sAdd=''
	window.location="getfile.asp?id=" + id + sAdd
}

