function popupUrl(url, width, height) {
	var w = window.open(url,'','toolbar=no,statusbar=no,location=no,scrollbars=no,resizable=yes,width=' + width + ',height=' + height);
	if (w) { w.focus(); }
}

function isEmail(e) {
	if (e.search(/^\w+((-\w+)|(\.\w+))*\@[A-Za-z0-9]+((\.|-)[A-Za-z0-9]+)*\.[A-Za-z0-9]+$/) != -1) {
		return true;
	} else {
		return false;
	}
}

function validateForm(str) {
	if (isEmail(str)) {
		return true;
	} else {
		var l = document.getElementById('email');
		if (l) {
			l.className = 'alert';
		}

		return false;
	}
}

function trackMe() {
	var host = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
	var s = document.createElement('script');
	if (s) {
		s.src = host + 'google-analytics.com/ga.js';
		s.type = "text/javascript";
		document.getElementsByTagName('head')[0].appendChild(s);
		var walk = 0;
		ga();
	}
 
	function ga() {
		if (typeof _gat == "object") {
			var p = _gat._getTracker("UA-5888764-1");
			if (p) {
				p._setDomainName('.monteverdi.tv');
				p._initData();
				p._trackPageview();
			}
		} else if (walk++ < 20) {
			setTimeout(ga, 500);
		}
	}
}

trackMe();

