<!--
window.defaultStatus = "";

function IMW_Find(o,d) {
	var p,i,x;
	if(!d) d=document;
	if((p=o.indexOf("?"))>0&&parent.frames.length) {
		d=parent.frames[n.substring(p+1)].document; o=o.substring(0,p);
	}
	if(!(x=d[o])&&d.all) x=d.all[o];
	for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][o];
	for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=IMW_Find(o,d.layers[i].document);
	if(!x && d.getElementById) x=d.getElementById(o); return x;
}

function IMW_Swap() {
	var i,j=0,x,a=IMW_Swap.arguments;
	document.IMW_sr=new Array;
	for(i=0;i<(a.length-2);i+=3) if((x=IMW_Find(a[i]))!=null){
		document.IMW_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];
	}
}

function IMW_Restore() {
	var i,x,a=document.IMW_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function IMW_Preload() {
	var d=document; if(d.images){
		if(!d.IMW_p) d.IMW_p=new Array();
		var i,j=d.IMW_p.length,a=IMW_Preload.arguments;
		for(i=0; i<a.length; i++) if (a[i].indexOf("#")!=0) {
			d.IMW_p[j]=new Image;
			d.IMW_p[j++].src=a[i];
		}
	}
}

function IMW_trackDiv() {
	var i,p,v,obj,args=IMW_trackDiv.arguments;
	for(i=0; i<(args.length-2); i+=3) if((obj=IMW_Find(args[i]))!=null) {
		v=args[i+2];
		if(obj.style) {
			obj=obj.style;
			v=(v=='show')?'visible':(v='hide')?'hidden':v;
		}
		obj.visibility=v;
	}
}

var isNN = (navigator.appName.indexOf("Netscape")!=-1);
function IMW_autoTab(input, len, e) {
	var keyCode = (isNN) ? e.which : e.keyCode;
	var filter = (isNN) ? [0,8,9] : [0,8,9,16,17,18,37,38,39,40,46];
	if(input.value.length>=len && !containsElement(filter,keyCode)) {
		input.value = input.value.slice(0, len);
		input.form[(getIndex(input)+1) % input.form.length].focus();
	}
	function containsElement(arr,ele) {
		var found = false, index = 0;
		while(!found && index<arr.length) {
			if(arr[index]==ele) found = true;
			else index++; return found;
		}
	}
	function getIndex(input) {
		var index = -1, i = 0, found = false;
		while(i<input.form.length && index==-1) { 
			if(input.form[i]==input)index = i;
			else i++;
		}
		return index;
	}
	return true;
}

function IMW_Opacity(id, begin, end, millisec) {
	var speed = Math.round(millisec/100);
	var timer = 0;
	if(begin >end) {
		for(i=begin; i>=end; i--) {
			setTimeout("IMW_ChangeOpacity("+i+",'"+id+"')",(timer*speed)); timer++;
		}
	}
	else if(begin <end) {
		for(i=begin; i<=end; i++) {
			setTimeout("IMW_ChangeOpacity("+i+",'"+id+"')",(timer*speed)); timer++;
		}
	}
}

function IMW_ChangeOpacity(opacity, id) {
	var obj = document.getElementById(id).style; 
	obj.opacity = (opacity/100);
	obj.MozOpacity = (opacity/100);
	obj.KhtmlOpacity = (opacity/100);
	obj.filter = "alpha(opacity="+opacity+")";
}

function IMW_ConfirmPDF() {
	document.PDF_returnVal = confirm(""
		+ "You are about to launch a PDF formatted document.   \n"
		+ "Receive your free copy of the Adobe PDF Reader at:   \n\n"
		+ "www.adobe.com/products/acrobat/readstep2.html   \n\n"
	);
}

//-->