imgs=(document.images) ? 1:0
	if(imgs){
		img1=new Image(1,1); img1.src="/images/topnav/join_on.gif";
		img2=new Image(1,1); img2.src="/images/topnav/news_on.gif";
		img3=new Image(1,1); img3.src="/images/topnav/downloads_on.gif";
		img4=new Image(1,1); img4.src="/images/topnav/support_on.gif";
		img5=new Image(1,1); img5.src="/images/topnav/members_on.gif";
		img6=new Image(1,1); img6.src="/images/topnav/webmail_on.gif";
	}
	overimg="";
	function swpimg(theimg,newsrc){
		if(imgs){
			oldsrc=document.images[theimg].src;
			overimg=theimg;
			document.images[theimg].src=newsrc;
			}
		}
	function swpback(){
		if(overimg!=""){
			if(imgs){
				document.images[overimg].src=oldsrc;
				}
			}
		}
function doClock() {
    var t = new Date(), a = doClock.arguments, str = "", i, a1, lang = "1";
    var month = new Array('January','Jan', 'February','Feb', 'March','Mar', 'April','Apr', 'May','May', 'June','Jun', 'July','Jul', 'August','Aug', 'September','Sep', 'October','Oct', 'November','Nov', 'December','Dec');
    var tday = new Array('Sunday','Sun','Monday','Mon', 'Tuesday','Tue', 'Wednesday','Wed','Thursday','Thr','Friday','Fri','Saturday','Sat');
    for (i = 0; i < a.length; i++) {
        a1 = a[i].charAt(1);
        switch (a[i].charAt(0)) {
          case "M":
            if ((Number(a1) == 3) && ((t.getMonth() + 1) < 10)) {
                str += "0";
            }
            str += (a1 == "2") ? t.getMonth() + 1 : month[t.getMonth() * 2 + Number(a1)];
            break;
          case "D":
            if ((Number(a1) == 1) && (t.getDate() < 10)) {
                str += "0";
            }
            str += t.getDate();
            break;
          case "Y":
            str += (a1 == "0") ? t.getFullYear() : t.getFullYear().toString().substring(2);
            break;
          case "W":
            str += tday[t.getDay() * 2 + Number(a1)];
            break;
          default:
            str += unescape(a[i]);
        }
    }
    return str;
}	

function NewWindow(mypage,myname,w,h,scroll,toolbar,location,status,menubar,resizable){
	LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
	TopPosition = (screen.height) ? (screen.height-h)/2 : 0;
	var settings  ='height='+h+',';
    	  settings +='width='+w+',';
	      settings +='top='+TopPosition+',';
    	  settings +='left='+LeftPosition+',';
	      settings +='scrollbars='+scroll+',';
		  settings +='toolbar='+toolbar+',';   	  
		  settings +='location='+location+','; 
		  settings +='status='+status+','; 
		  settings +='menubar='+menubar+',';  
	      settings +='resizable='+resizable;
	win = window.open(mypage,'myname',settings)
}

function getsearch(site_location){
var sel = document.searchform.searchoption.options[document.searchform.searchoption.selectedIndex].value;
var q = document.searchform.query.value; 
var b = document.searchform.search_param.value;
var searchpage = "";
	switch (sel) {
		case '1':
			//alert (sel);
			document.searchform.action="/"+site_location+"/0/0/0.htm?query="+q+"&search_param="+b;
			document.searchform.submit();
			break;
		case '2':
			//alert (sel);
			var searchpage = "http://www.google.com/custom?q="+q+"&sa=Search";
			break;
		case '3':
			//alert (sel);
			var searchpage = "http://nz.altavista.com/q?pg=q&q="+q+"&kl=xx&uhat=web";
			break;
		case '4':
			//alert (sel);
			var searchpage = "http://www.dogpile.com/texis/search?q="+q+"&geo=no&fs=web";
			break;
		case '5':
			//alert (sel);
			var searchpage = "http://www.askjeeves.com/main/askjeeves.asp?ask="+q+"&o=0";
			break;
		case '6':
			//alert (sel);
			var searchpage = "http://www.searchnz.co.nz/cgi-bin/search?q="+q+"&fm=&gr=";
			break;
	}
	
	if (searchpage != ""){
		NewWindow(searchpage,'index','800','500','yes','yes','yes','yes','yes','yes');
	}	
/*	
	if (!sel) {
		alert ('blbec vosiel do ifu');
		if (sel == 2) {
			var searchpage = "http://www.google.com/custom?q="+q+"&sa=Search";
		} else {
			if (sel == 3) {
				var searchpage = "http://nz.altavista.com/q?pg=q&q="+q+"&kl=xx&uhat=web";
			} else {
				if (sel == 4) {
					var searchpage = "http://www.dogpile.com/texis/search?q="+q+"&geo=no&fs=web";
				} else {
					if (sel == 5) {
						var searchpage = "http://www.askjeeves.com/main/askjeeves.asp?ask="+q+"&o=0";
					} else {
						if (sel == 6) {
							var searchpage = "http://www.searchnz.co.nz/cgi-bin/search?q="+q+"&fm=&gr=";
						}
					}
				}
			}
		}
		NewWindow(searchpage,'index','800','500','yes','yes','yes','yes','yes','yes');

	} else {
		alert (sel);
		document.search.action="/content/0/0/0.htm?query="+q+"&search_param="+b;
		document.search.submit();
	}*/
}

function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}






/****
* Banner Ad Rotater v3.02
* Anarchos > anarchos3@hotmail.com
* http://anarchos.xs.mw/bannerad.phtml
**/

function Banner(refreshTime, altText, width, height, start, random){
	this.objName = "bannerAd" + (Banner.count++);
	eval(this.objName + "=this");
	if (!refreshTime) this.refreshTime = 5000; else this.refreshTime = refreshTime*1000;
	if (!width) this.width = 460; else this.width = width;
	if (!height) this.height = 68; else this.height = height;
	if (random == null) this.random = 1; else this.random = random;
	this.altText = altText;
	this.ads = [];
	if (start) this.currentAd = start-1; else start = null;
	this.mySize = 0;

	this.Ad = function(src, href, target, mouseover) {		
		var tempImage = new Image();
		tempImage.src = src;
		this.ads[this.mySize] = new Object();
		var ad = this.ads[this.mySize];		
		ad.src = src;		
		//if (typeof(target) == "undefined" || target == null) ad.target = "_self"; else ad.target = target;
		//if ((typeof(hreflocation) == "undefined" || hreflocation == null) && hreflocation != "1") ad.target = "1"; else ad.target = "2";
		//alert(ad.target);
		ad.target = target;
		ad.href = href;				
		ad.mouseover = mouseover;
		this.mySize++;
	}

	this.link = function(){
		var	ad = this.ads[this.currentAd];
		
		if (ad.target == "2"){
			location.href = ad.href;
		}
		else if (ad.target == "1"){
			NewWindow(ad.href,'mouseover','700','500','yes','yes','yes','yes','yes','yes');
		}
		
		//if (ad.target == "_self"){
		//	location.href = ad.href;
		//}
		//else if (ad.target == "_blank" || ad.target == "_new"){
		//	open(ad.href,this.objName + "Win");
		//}
		
		
		else top.frames[ad.target].location.href = ad.href;
	}

	this.showStatus = function(){
		var ad = this.ads[this.currentAd];		
		if (ad.mouseover) status = ad.mouseover;			
		else status = ad.href;	
	}

	this.randomAd = function(){
		var n;
		do { n = Math.floor(Math.random() * (this.mySize)); } 
		while(n == this.currentAd);
		this.currentAd = n;
	}

	this.output = function(){
		this.currentAd = null; //to get random image from first of them(imeddiately after reload page)
		var tempCode = "";
		//if (this.mySize > 1){
			if (this.currentAd == null) this.randomAd();
			if (this.currentAd >= this.mySize) this.currentAd = this.mySize - 1;
			tempCode = '<a href="javascript:'+this.objName+'.link();"';
			tempCode += ' onMouseOver="' + this.objName + '.showStatus(); return true"';			
			tempCode += ' onMouseOut="status=\'\';return true">';
			tempCode += '<img src="' + this.ads[this.currentAd].src + '" width="' + this.width;
			tempCode += '" name="' + this.objName + 'Img" height="' + this.height + '" ';		
			if (this.altText) tempCode += 'alt="'+this.altText + '" ';
			tempCode += 'border="0" /></a>';
			document.write(tempCode);
			this.nextAd();
		//} else document.write("Error: two banners must be defined for the script to work.");
	}

	this.newAd = function(){
		if (!this.random){	
			this.currentAd++;
			if (this.currentAd >= this.mySize)
			   this.currentAd = 0;			   			   
		}		
		else {
			this.randomAd();			
		}
		this.nextAd();
	}

	this.nextAd = function(){
		document.images[this.objName+ 'Img'].src = this.ads[this.currentAd].src;		
		setTimeout(this.objName+'.newAd()',this.refreshTime)
	}
}
Banner.count = 0;