//	evation.js	Shared JS routines
//	(c)		Andy Belcher		2006
//	--------------------------------------
//
var domName		= "flyevation.co.uk";
//
function getObjectByAnyMeans(objId) {
	if(document.getElementById) {return document.getElementById(objId);}
	if(document.all)            {return eval("document.all." +objId);}
	if(document.layers)         {return eval("document.layers[" +objId+ "]");}
	return false;
	}
//
function dw(str) {document.write(str);}
//
function switchClass(lmtId,newClass)
	{getObjectByAnyMeans(lmtId).className = newClass;}
//
function switchText(lmtId,newText)
	{getObjectByAnyMeans(lmtId).innerHTML = newText;}
//
function browserUpgradeWarning() {
	dw("<div id=\"upgrade\"> "
		+ "Sorry, but your browser is either very old or not configured correctly, "
		+ "we shall assume the former! "
		+ "Some of the styling features within this site will not render "
		+ "correctly on your <strong>obsolete</strong> browser. You will still be "
		+ "able to use the site but it won't look as good. "
		+ "In the meantime you are strongly advised to upgrade your browser to "
		+ "at least <strong>Internet Explorer 6</strong> or one of the other "
		+ "standards compliant browsers such as <strong>FireFox</strong> or "
		+ "<strong>Opera</strong>, these are fully compliant and will work "
		+ "correctly.<br />Try these links for more information: "
		+ "<a href=\"http://webstandards.org/act/campaign/buc/\" target=\"_blank\" "
		+ "title=\"The Browser Upgrade Campaign...\">&raquo;Browser Upgrade Campaign</a> "
		+ "&#8212;<a href=\"http://www.w3.org/QA/\" target=\"_blank\" "
		+ "title=\"Find out more about web standards QA from the W3C...\""
		+ ">&raquo;W3C QA</a></div>");
	}
//
function aSMT(tN,tD,dA,sU) {
	var aS = "{at)";var mT = "ma"+"ilt"+"o:";if(!tD) {tD = domName;}
	var tA = tN+"@"+tD;if(!dA) {dA = tN+aS+tD;}
	if(sU) {sU = "?s"+"ub"+"ject="+sU;} else {sU = "";}
	dw("<a href=\""+mT+tA+sU+"\" title=\"Ema"+"il...\">"+dA+"</a>");
	}
//
//	EOF
//
