// Contains all Javascript to be executed on pageload

jQuery.noConflict();

window.onload = function() {
	// Informs IE/Mac users to GET A NEW BROWSER (If using IE/Mac && it's your first time viewing a page on this site)
	if ((navigator.appName.indexOf('Internet Explorer') > -1 && navigator.appVersion.indexOf('Mac') > -1) && document.referrer.indexOf(location.hostname) == -1) {
		alert("You are using an out of date browser and as such, this site may not display correctly.\n\nWe recommend you download a newer browser such as Firefox (www.mozilla.com) and use that.");
	}

	// Sets all <a> tags with rel="external" or rel="newpage" to open in a new window
	// Target attribute is not valid in Strict doctype... so we dynamically add it ;-)
	// Planned to evolve into a window.open()
	var links = $('a');
	if(links.length > 0) {
		for (i = 0 ; i < links.length ; i++) {
			if(links[i].rel && (links[i].rel == "external" || links[i].rel == "newpage")) {
				links[i].target = '_blank';
			}
		}
	}
	
}

jQuery(document).ready(convertMailto);
