

/* this is a way to prevent spam bots 
		-- adam (2/4/03)
*/

function sendEmail(user,domain,subject){
	subject = (subject) ? '?subject='+subject : '';
	location.href = 'mailto:'+user+'@'+domain+subject;
}

function NewWindow(mypage,myname,w,h,pos,scroll){ // scroll is optional - default set to 'no'
	if (NewWindow.arguments.length == 3){
		win = window.open(mypage,myname,w);
		return;
	}
	if(pos=="random"){LeftPosition=(screen.width)?Math.floor(Math.random()*(screen.width-w)):100;TopPosition=(screen.height)?Math.floor(Math.random()*((screen.height-h)-75)):100;}
	if(pos=="center"){LeftPosition=(screen.width)?(screen.width-w)/2:100;TopPosition=(screen.height)?(screen.height-h)/2:100;}
	if(pos.indexOf(",")!=-1){aPos=pos.split(",");LeftPosition=aPos[0];TopPosition=aPos[1];}
	scroll = scroll?scroll:'no';
	settings='width='+w+',height='+h+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=yes';
	var win=window.open(mypage,myname,settings);
	if(win.focus){win.focus();}
	return win;
}

function viewImage(u,w,h){
	NewWindow("/code/popup.asp?image="+u,"popup",w,h,'center');
}

function setMiscText(text){
	var div = document.getElementById("miscText");
	if (div) div.innerHTML = text;
}

function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}