var iPath  = '/shared/images/nav/';//buttons images location
var iExt   = 'gif';
var suffix = new Array('off', 'on');

function preLoad(){
	if(document.images){
		var argLen = arguments.length;
		for(var i = 0; i < argLen; i++){
			var arg = arguments[i];
			var sufLen = suffix.length;
			for(j = 0; j < sufLen; j++){
				var suf = suffix[j]
				self[arg + '_' + suf] = new Image();
				self[arg + '_' + suf].src = iPath + arg + '_' + suf + '.' + iExt;
			}
		}
	}
}


function rollOver(iName, iState){
	if(document.images && self[iName + '_' + iState]){
		document.images[iName].src = self[iName + '_' + iState].src;
	}
	return true;
}

function preLoad_bi(){ // preloads bingo nav images
	preLoad('75ball_btn','90number_btn','refresh','preorder');
}

function openNews(URL){
	var bhlnews = null;
	var LeftPosition = (screen.width) ? (screen.width-800)/2 : 0;
	if (LeftPosition < 0) LeftPosition = 0 ;
	var TopPosition = (screen.height) ? (screen.height-560)/2 : 0;
	if (TopPosition < 0) TopPosition = 0 ;
	var	specs = 'height=500,width=800,top='+TopPosition+',left='+LeftPosition+',scrollbars=yes,resizable=yes,toolbars=no,location=no,menubars=no,fullscreen=no'
	bhlnews = window.open(URL,"BHNews",specs);
	bhlnews.focus();
	return false;
}