function OpenSpecWin(filename, SortOrder) {
	var sWinOption, isPDF=false, isGIF=false, prefix="";
	if (isPDF = filename.match(/\.pdf$/i))
		sWinOption = "resizable,status";
	else if  (isGIF = filename.match(/\.(gif|jpg)$/i))
		sWinOption = "menubar=yes,resizable,status,scrollbars,width=680,height=460";
	else
		sWinOption = "menubar=yes,resizable=1,status=1,width=750,height=650,screenX=100,screenY=100,left=100,top=100,scrollbars=1";
	if (document.location.toString().match(/elitenet/i) && filename.indexOf("://")==-1 && filename.charAt(0)!="/")
		prefix = "../" ;
	if (isGIF) {
		if (isNaN(parseInt(SortOrder,10)))
			sText = "User clicked help for " + SortOrder;
		else
			sText = "User clicked help in " + SCT[SortOrder].Description + " section.";
		uc(sText);
		winSpecs = window.open(prefix+filename, 'gifimage', sWinOption);
	} else {	//if (isPDF) {
		if (isNaN(parseInt(SortOrder,10)))
			sText = "User clicked help for " + SortOrder;
		else
			sText = "User clicked help in " + SCT[SortOrder].Description + " section.";
		uc(sText);
		winSpecs = window.open(prefix+filename, 'pdffile', sWinOption);
	} 
	/*else {
		if (isNaN(parseInt(SortOrder,10)))
			sText = "User clicked help for " + SortOrder + " (WITHOUT FLASH)";
		else
			sText = "User clicked help in " + SCT[SortOrder].Description + " section (WITHOUT FLASH).";
		uc(sText);
		winSpecs = window.open(prefix+"help/noflash/noflash.htm");
	}*/
}

function replace(fullS,oldS,newS) {
    fullS = '' + fullS
    fullS = fullS.replace(oldS, newS);
    return fullS
}


