
/** creates an extra stylesheet **/
function addstyles(){

	//** Build js rendered stylesheet that css validators fail on **
	var jstyle = document.getElementsByTagName("head")[0];
	var lk = document.createElement("link");
	jstyle.appendChild(lk);
	lk.setAttribute("rel", "stylesheet");
	lk.setAttribute("type", "text/css");
	lk.setAttribute("href", "/js-vl.css");
}


/** loop function for fading and moving objects - start **/
function valueCounter(id, opacStart, opacEnd, tFunction, millisec) { 

var speed = Math.round(millisec / 100); 
var timer = 10; 

if(opacStart > opacEnd) { 
 for(i = opacStart; i >= opacEnd; i--) { 
     setTimeout("changeValues(" + i + ",'" + id + "','" + tFunction + "')",(timer * speed)); 
     timer++; 
 } 
} else if(opacStart < opacEnd) { 
 for(i = opacStart; i <= opacEnd; i++) 
 { 
     setTimeout("changeValues(" + i + ",'" + id + "','" + tFunction + "')",(timer * speed)); 
     timer++; 
 } 
} 
} 

function changeValues(nValue, id, tFunction) { 
	
	if(tFunction == "opacity")
	{
		var object = document.getElementById(id).style; 
		object.filter = "alpha(opacity=" + nValue + ")"; 
		object.opacity = (nValue / 100); 
		object.MozOpacity = (nValue / 100); 
		object.KhtmlOpacity = (nValue / 100); 
	}
	else if(tFunction == "top")
	{
		document.getElementById(id).style.top = "-"+nValue+"px";
	}
}
/** loop function for fading and moving objects - end **/



/** convert standard links with 'rel' of 'pop' into inline popup **/
function popLinks(){

	poplinks = document.getElementsByTagName("a");
	for(i=0;i<poplinks.length;i++)
	{
		popLink = poplinks[i];
		linkRel = popLink.getAttribute("rel");
		
		if(linkRel == "pop")
		{
			linkHref = popLink.getAttribute("href");
			newLinkHrefA = linkHref.replace(/http:\/\//g, "");
			newLinkHrefB = newLinkHrefA.split("/");
			popinfo = newLinkHrefB[1].replace(/[^a-z-]/g, "");
			poplinks.item(i).setAttribute("href","javascript:popInfo('"+popinfo+"')");
		}
	}
}

/** creates an inline popup **/
function popInfo(popinfo){

	if(!document.getElementById("popinfo"))
	{
		var parentBody = document.getElementsByTagName("body")[0];
		var popdiv = document.createElement("div");
		var popinner = document.createElement("div");
		var popclose = document.createElement("a");
		parentBody.appendChild(popdiv);
		popdiv.appendChild(popclose);
		popdiv.appendChild(popinner);
		popdiv.setAttribute("id", "popinfo");
		popinner.setAttribute("id", "popcontent");
		popclose.setAttribute("id", "popclose");
		popclose.setAttribute("title", "Close pop-up info box - click here");
		popclose.setAttribute("href", "javascript:popInfoClose()");
	}
	
	if(bName == "Explorer")
	{
		document.getElementById("popinfo").style.backgroundImage = "none";
	}
	
	var xmlhttp;
	if (window.XMLHttpRequest)
	{
		// code for IE7+, Firefox, Chrome, Opera, Safari
		xmlhttp=new XMLHttpRequest();
	}
	else if (window.ActiveXObject)
	{
		// code for IE6, IE5
		xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
	}
	else
	{
		alert("Your browser does not support XMLHTTP!");
	}
	
	document.getElementById("popinfo").style.display = "block";
	valueCounter('popinfo',0,100,'opacity',200);
	
	xmlhttp.onreadystatechange=function()
	{
		if(xmlhttp.readyState==4)
		{
			document.getElementById("popcontent").innerHTML= '';	
			document.getElementById("popcontent").innerHTML=xmlhttp.responseText;
			
			if(bName == "Explorer")
			{
				var RemFilTimer = setTimeout("document.getElementById('popinfo').style.filter = ''",300);
				var AddBGTimer = setTimeout("document.getElementById('popinfo').style.background = 'transparent url(/gfx/info-pop.png) no-repeat center center'",400);
			}
		}
	}
	
	var whichPage = "/popcontent/"+popinfo;
	xmlhttp.open("GET",whichPage,true);
	xmlhttp.send(null);
}


function popInfoClose(){

	if(bName == "Explorer")
	{
		document.getElementById("popinfo").style.backgroundImage = "none";
	}
	
	valueCounter('popinfo',100,0,'opacity',200);
	touterdisp = setTimeout("document.getElementById('popinfo').style.display = 'none'",200);
	touterhtml = setTimeout("document.getElementById('popcontent').innerHTML = ''",200);
}


function extendPage(){

	pageHeight = document.getElementById("page").offsetHeight;
	contentHeight = document.getElementById("content").offsetHeight;
	containerHeight = document.getElementById("container").offsetHeight;
	
	sHeight = 401;
	rHeight = pageHeight-containerHeight;
	nheight = rHeight+266;
	
	if(pageHeight>714 && contentHeight < 545)
	{
		document.getElementById("container").style.paddingBottom = rHeight+"px";
		document.getElementById("page").style.bottom = nheight+"px";
	}
}


function checkForm(formreq,formname){

	if(reqFields.length > 0)
	{
		chkDetails = new Array();
		chkDetails['num'] = 0;
		chkDetails['mssg'] = 'Please fill in all required fields.<br /><br />';
		var efilter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i


		for(i=0;i<reqFields.length;i++)
		{
			fieldname = reqFields[i];
			fieldlabel = reqFields[i].replace(/-/g," ");

			if(fieldname == "email")
			{
				tcfemail = document.forms[formname].elements[fieldname].value;
				if(efilter.test(tcfemail))
				{
					chkDetails['num'] = chkDetails['num']+1;
				}
				else
				{
					chkDetails['mssg'] += "- Please enter a valid Email Address\<br />";
				}
			}
			else if(fieldname == "phone" || fieldname == "budget")
			{
				tcfphone = document.forms[formname].elements[fieldname].value; cfphone = tcfphone.replace(/ /gi,"");
				if(isNaN(cfphone) || cfphone == "")
				{
					chkDetails['mssg'] += "- Please enter a valid Number<br />";
				}
				else
				{
					chkDetails['num'] = chkDetails['num']+1;
				}

			}
			else
			{
				if(document.forms[formname].elements[fieldname].length > 1)
				{
					var gSv;
					for (var g=0; g < document.forms[formname].elements[fieldname].length; g++)
					{
						if (document.forms[formname].elements[fieldname][g].checked)
						{
							chkDetails['num'] = chkDetails['num']+1;
							gSv = "1";
						}
					}

					if(gSv != "1")
					{
						fieldlabelU = fieldlabel.charAt(0).toUpperCase() + fieldlabel.slice(1);
						chkDetails['mssg'] += "- "+fieldlabelU+"<br />";
					}
				}
				else
				{
					tcfthisfield = document.forms[formname].elements[fieldname].value; cfthisfield = tcfthisfield.replace(/ /gi,"");
					if(cfthisfield != "")
					{
						chkDetails['num'] = chkDetails['num']+1;
					}
					else
					{
						fieldlabelU = fieldlabel.charAt(0).toUpperCase() + fieldlabel.slice(1);
						chkDetails['mssg'] += "- "+fieldlabelU+"<br />";
					}
				}
			}

		}

		if(chkDetails['num'] == reqFields.length)
		{
			return true;
		}
		else
		{

			if (self.pageYOffset)
			{
				var scrolling = self.pageYOffset;
			}
			else
			{
				var scrolling = document.documentElement.scrollTop;
			}

			var errPos = scrolling+130;
			errorid = "cterrorpop";

			if(!document.getElementById(errorid))
			{
				var errBody = document.getElementsByTagName("body")[0];
				var errDiv = document.createElement("div");
				errBody.appendChild(errDiv);
				errDiv.setAttribute("id", errorid);
			}

			chkDetails['mssg'] += '<span id="errConf" onclick="hideErr()">OK</div>';

			document.getElementById(errorid).innerHTML = chkDetails['mssg'];

			document.getElementById(errorid).style.opacity = "0";
			document.getElementById(errorid).style.filter = "alpha(opacity=0)";

			document.getElementById(errorid).style.display = "block";

			errDivMarginV = document.getElementById(errorid).offsetHeight;
			errDivMargin = Math.round(errDivMarginV/2);
			document.getElementById(errorid).style.marginTop = "-"+errDivMargin+"px";

			document.getElementById(errorid).style.opacity = "1";
			document.getElementById(errorid).style.filter = "alpha(opacity=100)";
			return false;
		}
	}
}


function hideErr(){

		document.getElementById(errorid).innerHTML = '';
		document.getElementById(errorid).style.display = "none";
}


/*** calendar code start ***/

/******calendar html
* <div id="calendar">
* <div id="thisyear"></div>
* <div id="days"></div>
* <script type="text/javascript">startCalendar();</script>
* </div>
*******/

months = new Array();
months['january'] = "0";
months['february'] = "1";
months['march'] = "2";
months['april'] = "3";
months['may'] = "4";
months['june'] = "5";
months['july'] = "6";
months['august'] = "7";
months['september'] = "8";
months['october'] = "9";
months['november'] = "10";
months['december'] = "11";

pmonths = new Array();
pmonths[0] = "january";
pmonths[1] = "february";
pmonths[2] = "march";
pmonths[3] = "april";
pmonths[4] = "may";
pmonths[5] = "june";
pmonths[6] = "july";
pmonths[7] = "august";
pmonths[8] = "september";
pmonths[9] = "october";
pmonths[10] = "november";
pmonths[11] = "december";

function startCalendar()
{
	var d = new Date();
	year = d.getFullYear();
	thismonth = d.getMonth();
	month = pmonths[thismonth];
	myCalendar(year,thismonth,month);
}

function myCalendar(year,thismonth,month,calToday){

	fnDate = new Date();

	yearDiv = document.getElementById("thisyear");
	dayDiv = document.getElementById("days");

	monthTempA = month;
	monthTempB = months[monthTempA];
	prevmonthtemp = parseInt(monthTempB)-1;
	nxtmonthtemp = parseInt(monthTempB)+1;

	if(month == "december")
	{
		prevmonth = pmonths[prevmonthtemp];
		nprevmonth = prevmonthtemp;
		nxtmonth = "january";
		nnxtmonth = "0";
		prevyear = year;
		nxtyear = parseInt(year)+1;
	}
	else if(month == "january")
	{
		prevmonth = "december";
		nprevmonth = "11";
		nxtmonth = pmonths[nxtmonthtemp];
		nnxtmonth = nxtmonthtemp;
		prevyear = parseInt(year)-1;
		nxtyear = year;
	}
	else
	{
		prevmonth = pmonths[prevmonthtemp];
		nprevmonth = prevmonthtemp;
		nxtmonth = pmonths[nxtmonthtemp];
		nnxtmonth = nxtmonthtemp;
		prevyear = year;
		nxtyear = year;
	}

	prevdate = prevmonth+'-'+prevyear;
	nxtdate = nxtmonth+'-'+nxtyear;
	
	umonthtxt = month.charAt(0).toUpperCase() + month.slice(1);

	totaldays = readDaysInMonth(thismonth,year);
	getFirstDay = new Date(year,thismonth,1);
	dateToS = getFirstDay.getDay();
	
	if(dateToS == 0)
	{
		dateToS = 8;
		startCountDays = 44;		
	}
	else if(dateToS == 5 || dateToS == 6)
	{
		dateToS = dateToS+1;
		startCountDays = 44;
	}
	else if(totaldays == 28)
	{
		dateToS = 10;
		startCountDays = 45;
	}
	else
	{
		dateToS = dateToS;
		startCountDays = 43;
	}
	
	yearDiv.innerHTML = '';
	yeartostop = fnDate.getFullYear()-2;
	monthtostop = fnDate.getMonth()+1;
	currentyear = fnDate.getFullYear();
	if(prevyear < yeartostop)
	{
		yearDiv.innerHTML += '<a id="prevmonth">&laquo;</a>';
	}
	else
	{
		yearDiv.innerHTML += '<a id="prevmonth" title="View '+prevmonth+' '+prevyear+'" onclick="myCalendar(\''+prevyear+'\',\''+nprevmonth+'\',\''+prevmonth+'\')">&laquo;</a>';
	}
	
	yearDiv.innerHTML += '<span id="actYear">'+umonthtxt+' '+year+'</span>';
	
	if((nnxtmonth == monthtostop) && (nxtyear == currentyear))
	{
		yearDiv.innerHTML += '<a id="nxtmonth">&raquo;</a>';
	}
	else
	{
		yearDiv.innerHTML += '<a  id="nxtmonth" title="View '+nxtmonth+' '+nxtyear+'" onclick="myCalendar(\''+nxtyear+'\',\''+nnxtmonth+'\',\''+nxtmonth+'\')">&raquo;</a>';
	}
	
	dayDiv.innerHTML = '';
	for(d=1;d<dateToS;d++)
	{
		getThisDayC = new Date(year,thismonth,d);
		dateToCC = getThisDayC.getDay();
		
		if(dateToCC != 1)
		{
			dayDiv.innerHTML += '<a rel="calDay" class="dayitemblank" href="javascript:;"></a>';
		}
	}
	
	stopCountDays = startCountDays-dateToS;
	
	for(i=0;i<stopCountDays;i++)
	{
		day = i+1;
		getThisDay = new Date(year,thismonth,day);
		dateToC = getThisDay.getDay();
		
		tnfday = day.toString();
		if(tnfday.length<2)
		{
			tnday = '0'+tnfday;
		}
		else
		{
			tnday = tnfday;
		}

		nday = tnday;
		nday.split("");
		dayhtml = nday[1];
		dayhtmlf = nday[0];

		if(dayhtmlf == "1")
		{
			mydath = "th";
		}
		else
		{
			if(dayhtml == "1")
			{
				mydath = "st";
			}
			else if(dayhtml == "2")
			{
				mydath = "nd";
			}
			else if(dayhtml == "3")
			{
				mydath = "rd";
			}
			else
			{
				mydath = "th";
			}
		}

		senddate = day+mydath+" "+month+" "+year;

		dispday = day;
		if(day<10){dispday = "0"+day;}
		dispmonth = parseInt(months[month])+1;
		if((parseInt(months[month])+1)<10){dispmonth = "0"+(parseInt(months[month])+1);}
		sendcdate = dispday+"-"+dispmonth+"-"+year;
		
		if(day > totaldays)
		{
			dayDiv.innerHTML += '<a rel="calDay" class="dayitemblank" href="javascript:;"></a>';
		}
		else
		{
			dayDiv.innerHTML += '<a rel="calDay" title="View posts for the '+senddate+'" class="dayitem" href="/latest/'+sendcdate+'">'+day+'</a>';
		}

		hightlightToday();
	}
}

function hightlightToday(){

	var d = new Date();
	year = d.getFullYear();
	thismonth = d.getMonth();
	month = pmonths[thismonth];
	day = d.getDate();

	fsMonthYear = document.getElementById("actYear").innerHTML;
	
	umonthtxt = month.charAt(0).toUpperCase() + month.slice(1);
	curdttext = umonthtxt+' '+year;

	if(curdttext == fsMonthYear)
	{
		calDays = document.getElementById("days").getElementsByTagName("a");
		for(d=0;d<calDays.length;d++)
		{
			calDay = calDays[i];
			thisREL = calDay.getAttribute("rel");
			thisHTML = calDay.innerHTML;
			if(thisREL=="calDay" && thisHTML == day)
			{
				calDays.item(i).style.backgroundColor = '#fafe93';
				calDays.item(i).style.color = '#000000';
				calDays.item(i).style.fontWeight = 'bold';
			}
		}
	}
}


function isLeapYear(year){

return ((year%4 == 0) && (year%100 != 0 || year%400 == 0));

}

function readDaysInMonth(month,year)
{
    if (month == 1 && isLeapYear(year) == true) return 29;
    else return [31,28,31,30,31,30,31,31,30,31,30,31][month];
}

function showday(thisdate,thiscdate){

	top.location = "/latest/"+thiscdate;
}
/*** calendar code end ***/


/*** switches text and background colours ***/
function highlighttxt(){

backgroundswitch = '#000000';
textswitch = '#fbf30e';
linkswitch = '#3bd711';

paras = document.getElementsByTagName("p");
headsa = document.getElementsByTagName("h1");
headsb = document.getElementsByTagName("h2");
headsc = document.getElementsByTagName("h3");
headsd = document.getElementsByTagName("h4");
alinks = document.getElementsByTagName("a");
liitems = document.getElementsByTagName("li");
labels = document.getElementsByTagName("label");
divs = document.getElementsByTagName("div");
inputs = document.getElementsByTagName("input");

	document.getElementsByTagName("body")[0].style.backgroundColor = backgroundswitch;
	
	for (var i=0; i<paras.length; i++) 
	{   
		var para = paras[i];  
 		paras.item(i).style.color = textswitch;
 		paras.item(i).style.backgroundColor = backgroundswitch;
	}
	
	for (var i=0; i<headsa.length; i++) 
	{   
		var heada = headsa[i];  
 		headsa.item(i).style.color = textswitch;
	}
	
	for (var i=0; i<headsb.length; i++) 
	{   
		var headb = headsb[i];  
 		headsb.item(i).style.color = textswitch;
	}
	
	for (var i=0; i<headsc.length; i++) 
	{   
		var headc = headsc[i];  
 		headsc.item(i).style.color = textswitch;
	}
	
	for (var i=0; i<headsd.length; i++) 
	{   
		var headd = headsd[i];  
 		headsd.item(i).style.color = textswitch;
	}
	
	for (var i=0; i<alinks.length; i++) 
	{   
		var alink = alinks[i];  
 		alinks.item(i).style.color = linkswitch;
 		alinks.item(i).style.backgroundColor = backgroundswitch;
 		alinks.item(i).style.textDecoration ="underline";
	}
	
	for (var i=0; i<liitems.length; i++) 
	{   
		var liitem = liitems[i];  
 		liitems.item(i).style.color = textswitch;
 		liitems.item(i).style.backgroundColor = backgroundswitch;
	}
	
	for (var i=0; i<labels.length; i++) 
	{   
		var labelss = labels[i];  
 		labels.item(i).style.color = textswitch;
	}
	
	for (var i=0; i<divs.length; i++) 
	{   
		var divss = divs[i];  
 		divs.item(i).style.backgroundColor = backgroundswitch;
 		divs.item(i).style.color = textswitch;
	}
	
	for (var i=0; i<inputs.length; i++) 
	{   
		var inputss = inputs[i];  
 		inputs.item(i).style.backgroundColor = backgroundswitch;
 		inputs.item(i).style.color = textswitch;
	}
	
}


function ieWarning(){

	if(bName == "Explorer" && bVer == "6")
	{
		if(showIeWarning == "true")
		{
			if(!document.getElementById("iewarning"))
			{
				var ieBody = document.getElementsByTagName("body")[0];
				var ieDiv = document.createElement("div");
				ieBody.appendChild(ieDiv);
				ieDiv.setAttribute("id", "iewarning");
			}
			document.getElementById("iewarning").innerHTML = 'It appears you are using an old web browser such as Internet Explorer 6. It is recommended that you upgrade to the latest version of Internet Explorer or another modern web browser such as FireFox or Google Chrome. Some features of this website will not display correctly or are not compatible with Internet Explorer 6. To learn more about why you might be seeing this warning please visit <a href="http://www.atdc.co.uk/latest/16/hdybihini" target="_blank" title="Visit http://www.atdc.co.uk/latest/16/hdybihini [opens new window]">www.atdc.co.uk</a>. <a href="/stopwarning" id="closewarning">Close <img src="/gfx/close.gif" alt="close" width="10" height="10" style="vertical-align:middle;" /></a>';
			
			document.getElementById("iewarning").onmouseover = function(){document.getElementById("iewarning").style.backgroundColor = '#fdf9c0';}
			document.getElementById("iewarning").onmouseout = function(){document.getElementById("iewarning").style.backgroundColor = '#fffde2';}
		}
	}
}

function highlightMenu(){

	links = document.getElementById("menu").getElementsByTagName("a");
	curpage = location.pathname;
	
	for(i=0;i<links.length;i++)
	{
		link = links[i];
		thisHref = link.getAttribute("href");
		thisRel = link.getAttribute("rel");
		
		if(thisRel == "leftmenu" && thisHref == curpage)
		{
			links.item(i).className = "current";
		}
	}
}

function elementHide(cElement){

	elemArr = cElement.split(',');
	
	styleHTML='';
	for(i=0;i<elemArr.length;i++)
	{
		if(elemArr[i].substr(0,1)=="." || elemArr[i].substr(0,1)=="#")
		{
			styleHTML += elemArr[i]+"{display:none;}\n";
		}
	}
	
	var jxstyle = document.getElementsByTagName("head")[0];
	var xlk = document.createElement("style");
	var fstyles = document.createTextNode(styleHTML);
	xlk.setAttribute("type", "text/css");

	if(xlk.styleSheet){xlk.styleSheet.cssText = fstyles.nodeValue;}
	else{ xlk.appendChild(fstyles);}
	jxstyle.appendChild(xlk);
}


function swapLarge(img){

	imgArr = img.split("/");
	
	imgNm = imgArr[imgArr.length-1];
	
	document.getElementById("bg").src = '/images/'+imgNm;
	document.getElementById("flzi").href = '/images/full-s/'+imgNm;
	
	toggleImage(0,'fl');
}


function toggleImage(tg,id){
	
	ziID = id+"zi";
	zoID = id+"zo";

	if(tg == 1)
	{
		document.getElementById(id).style.display = "block";
		document.getElementById(zoID).style.display = "block";
		document.getElementById(ziID).style.display = "none";
	}
	else
	{
		document.getElementById(id).style.display = "none";
		document.getElementById(zoID).style.display = "none";
		document.getElementById(ziID).style.display = "block";
	}

}


/** http://www.quirksmode.org/js/detect.html           **/
var BrowserDetect = {
	init: function () {
		this.browser = this.searchString(this.dataBrowser) || "An unknown browser";
		this.version = this.searchVersion(navigator.userAgent)
			|| this.searchVersion(navigator.appVersion)
			|| "an unknown version";
		this.OS = this.searchString(this.dataOS) || "an unknown OS";
	},
	searchString: function (data) {
		for (var i=0;i<data.length;i++)	{
			var dataString = data[i].string;
			var dataProp = data[i].prop;
			this.versionSearchString = data[i].versionSearch || data[i].identity;
			if (dataString) {
				if (dataString.indexOf(data[i].subString) != -1)
					return data[i].identity;
			}
			else if (dataProp)
				return data[i].identity;
		}
	},
	searchVersion: function (dataString) {
		var index = dataString.indexOf(this.versionSearchString);
		if (index == -1) return;
		return parseFloat(dataString.substring(index+this.versionSearchString.length+1));
	},
	dataBrowser: [
		{
			string: navigator.userAgent,
			subString: "Chrome",
			identity: "Chrome"
		},
		{ 	string: navigator.userAgent,
			subString: "OmniWeb",
			versionSearch: "OmniWeb/",
			identity: "OmniWeb"
		},
		{
			string: navigator.vendor,
			subString: "Apple",
			identity: "Safari",
			versionSearch: "Version"
		},
		{
			prop: window.opera,
			identity: "Opera"
		},
		{
			string: navigator.vendor,
			subString: "iCab",
			identity: "iCab"
		},
		{
			string: navigator.vendor,
			subString: "KDE",
			identity: "Konqueror"
		},
		{
			string: navigator.userAgent,
			subString: "Firefox",
			identity: "Firefox"
		},
		{
			string: navigator.vendor,
			subString: "Camino",
			identity: "Camino"
		},
		{		// for newer Netscapes (6+)
			string: navigator.userAgent,
			subString: "Netscape",
			identity: "Netscape"
		},
		{
			string: navigator.userAgent,
			subString: "MSIE",
			identity: "Explorer",
			versionSearch: "MSIE"
		},
		{
			string: navigator.userAgent,
			subString: "Gecko",
			identity: "Mozilla",
			versionSearch: "rv"
		},
		{ 		// for older Netscapes (4-)
			string: navigator.userAgent,
			subString: "Mozilla",
			identity: "Netscape",
			versionSearch: "Mozilla"
		}
	],
	dataOS : [
		{
			string: navigator.platform,
			subString: "Win",
			identity: "Windows"
		},
		{
			string: navigator.platform,
			subString: "Mac",
			identity: "Mac"
		},
		{
			string: navigator.platform,
			subString: "Linux",
			identity: "Linux"
		}
	]

};
BrowserDetect.init();

var bName = BrowserDetect.browser;
var bVer = BrowserDetect.version;



window.onload = function (){popLinks();extendPage();if(bName == "Explorer" && bVer == "6"){ieWarning();}}
