/* Copyright NetCore 1997-2008. Licenced to Ash Alom. ash [AT] netcore [Dot COM]
*******************************************************************************/


//window.onerror=stopError;
//function stopError(){return true;}

var bV=parseInt(navigator.appVersion);
var NS4=(document.layers)?true:false;
var IE4=((document.all)&&(bV>=4))?true:false;
var ver4=(NS4||IE4)?true:false;
var VerMinor=parseFloat(navigator.appVersion);	// ex. 3.01
var OS;
if (navigator.appVersion.toLowerCase().indexOf("win")!=-1) {OS = "Win";}
if (navigator.appVersion.toLowerCase().indexOf("mac")!=-1) {OS = "Mac";};


function ValidateeMail(DOM){
	var NetCore
	var filter=/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,4})$/
	if (filter.test(DOM)){
		NetCore=true
	}else{
		NetCore=false
	}
	return (NetCore)
}


function ChangeImages(){
	//NetCore 2000
	document[ChangeImages.arguments[0]].src=eval(ChangeImages.arguments[1]+".src");
}

//document.write("<div style=background:Gray;Gold;Padding:3px;MArgin-Bottom:7px;Color:Black;Font-Size:8pt;Font-Family:Verdana;><marquee behavior=alternate><b>&#66;&#69;&#84;&#65;&#32;&#86;&#69;&#82;&#83;&#73;&#79;&#78;&#58;</b> &#49;&#46;&#51;&#46;&#56;7 &nbsp; &nbsp; &nbsp; &bull;&bull;&bull; &nbsp; &nbsp; &nbsp;&#67;&#111;&#110;&#116;&#97;&#99;&#116;&#32;&#65;&#115;&#104;&#32;&#105;&#102;&#32;&#121;&#111;&#117;&#32;&#102;&#105;&#110;&#100;&#32;&#97;&#110;&#121;&#32;&#98;&#117;&#103;&#115;&#58;&#32;&#97;&#115;&#104;&#97;&#108;&#111;&#109;&#64;&#103;&#109;&#97;&#105;&#108;&#46;&#99;&#111;&#109;</marquee></div>");

function Decode64(inp){
	var out = ""; //This is the output
	var chr1, chr2, chr3 = ""; //These are the 3 decoded bytes
	var enc1, enc2, enc3, enc4 = ""; //These are the 4 bytes to be decoded
	var i = 0; //Position counter

	// remove all characters that are not A-Z, a-z, 0-9, +, /, or =
	var base64test = /[^A-Za-z0-9\+\/\=]/g;

	if (base64test.exec(inp)) { //Do some error checking
		alert("There were invalid base64 characters in the input text.\n" +
		"Valid base64 characters are A-Z, a-z, 0-9, ?+?, ?/?, and ?=?\n" +
		"Expect errors in decoding.");
	}
	inp = inp.replace(/[^A-Za-z0-9\+\/\=]/g, "");

	do { //Here.s the decode loop.

		//Grab 4 bytes of encoded content.
		enc1 = keyStr.indexOf(inp.charAt(i++));
		enc2 = keyStr.indexOf(inp.charAt(i++));
		enc3 = keyStr.indexOf(inp.charAt(i++));
		enc4 = keyStr.indexOf(inp.charAt(i++));

		//Heres the decode part. There.s really only one way to do it.
		chr1 = (enc1 << 2) | (enc2 >> 4);
		chr2 = ((enc2 & 15) << 4) | (enc3 >> 2);
		chr3 = ((enc3 & 3) << 6) | enc4;

		//Start to output decoded content
		out = out + String.fromCharCode(chr1);

		if (enc3 != 64) {
			out = out + String.fromCharCode(chr2);
		}
		if (enc4 != 64) {
			out = out + String.fromCharCode(chr3);
		}

		//now clean out the variables used
		chr1 = chr2 = chr3 = "";
		enc1 = enc2 = enc3 = enc4 = "";

	} while (i < inp.length); //finish off the loop

	//Now return the decoded values.
	return out;
}