﻿// JScript File
    function offsetLeft(){
    }
    
	function checkLeftNavigation(){
		var links = document.getElementsByName("leftnavlink");
		//alert(links.length);
		//alert(window.location.pathname.toString());
		
		if (links) {
			var currentUrl = window.location.pathname.toString();
			var filename = currentUrl.substring(currentUrl.lastIndexOf("/") + 1);
			//alert ("current filename: -" + filename + "-");
			for(var i = 0; i<links.length; i++ )
			{
				//alert(links[i].href);
				var linkfilename = links[i].href.toString().substring(links[i].href.toString().lastIndexOf("/")+1);
				
				//if it contains '?', get rid the query string
				if(linkfilename.indexOf("?")>0)
					linkfilename = linkfilename.substring(0,linkfilename.indexOf("?"));
				
				//alert ("-" + linkfilename + "-");
				if (filename == linkfilename) {
					links[i].className = "leftNavCell_on";
				}
			}
		}
	}
		
function newImage(arg) {
		if (document.images) {
			rslt = new Image();
			rslt.src = arg;
			return rslt;
		}
	}
	
	function changeImages() {
		if (document.images) {
			for (var i=0; i<changeImages.arguments.length; i+=2) {
				document[changeImages.arguments[i]].src = changeImages.arguments[i+1];
			}
		}
	}
	
	function showmenu(elmnt)
	{
		var the_inputs=document.getElementsByTagName("select");
		
		for(var n=0;n<the_inputs.length;n++){
			the_inputs[n].style.visibility="hidden";
		}
		document.getElementById(elmnt).style.visibility="visible";
		document.getElementById(elmnt).style.display="block";
	}
	
	function hidemenu(elmnt)
	{
		var the_inputs=document.getElementsByTagName("select");
		
		for(var n=0;n<the_inputs.length;n++){
			the_inputs[n].style.visibility="visible";
		}
		document.getElementById(elmnt).style.visibility="hidden";
		document.getElementById(elmnt).style.display="none";
	}

	var coordinates=new Object();
	
	function thisDetails() {
		document.getElementById('about').style.left = parseInt(coordinates.x)+0+"px";
		document.getElementById('about').style.top = parseInt(coordinates.y)+13+"px";
		
		document.getElementById('invOpp').style.left = parseInt(coordinates.x)+93+"px";
		document.getElementById('invOpp').style.top = parseInt(coordinates.y)+13+"px";
		
		
		document.getElementById('invEdu').style.left = parseInt(coordinates.x)+305+"px";
		document.getElementById('invEdu').style.top = parseInt(coordinates.y)+13+"px";
	}
	
	var onMenu = false;
	var onButton = false;
	
	function getAnchorWindowPosition(anchorname) {
		var coordinates=getAnchorPosition(anchorname);
		var x=0;
		var y=0;
		if (document.getElementById) {
			if (isNaN(window.screenX)) {
				x=coordinates.x-document.body.scrollLeft+window.screenLeft;
				y=coordinates.y-document.body.scrollTop+window.screenTop;
				}
			else {
				x=coordinates.x+window.screenX+(window.outerWidth-window.innerWidth)-window.pageXOffset;
				y=coordinates.y+window.screenY+(window.outerHeight-24-window.innerHeight)-window.pageYOffset;
				}
			}
		else if (document.all) {
			x=coordinates.x-document.body.scrollLeft+window.screenLeft;
			y=coordinates.y-document.body.scrollTop+window.screenTop;
			}
		else if (document.layers) {
			x=coordinates.x+window.screenX+(window.outerWidth-window.innerWidth)-window.pageXOffset;
			y=coordinates.y+window.screenY+(window.outerHeight-24-window.innerHeight)-window.pageYOffset;
			}
		coordinates.x=x;
		coordinates.y=y;
		return coordinates;
	}
	
	
	//<![CDATA[ 
	/*window.onresize = restorePage
	function restorePage(){
		window.location.href=unescape(window.location.pathname);
	}*/
	
	function popPage2 (pageURL) {
	popUp = window.open(pageURL, 'Print', 'width=375,height=375,left=0,top=50,scrollbars=1,resizable=no,menubar=0');
    }
	//]]>

    <!-- Start DI Tracking Code for HEAD section-->
    var refr=escape(document.referrer); /* get the http referer and encode it */
    var dom=location.hostname; /* get the host domain */
    var stURL="http://link.decideinteractive.com/n/19643/19649/www.2020directinvest.com.au/e0fbf9e0002503000000000600000000038765440000000000000000000000000000000100/i/c?0&1pixgif&referer="
    + refr;
    if ( (refr && refr.search(dom) == -1) && (location.href.toUpperCase().indexOf("247SEO=N") == -1) ) /* if the referrer is external preload the image request and does not contain 247SEO argument = "N" */
    {
    imageTR = new Image();
    imageTR.src = stURL;
    }

    <!-- End DI Tracking Code -->