function psWin(){
	window.open("privacy.html","_blank","fullscreen=no,toolbar=no,location=no,status=no,menubar=no,resizable=no,height=600,width=400,top=O,left=0")
}

function validator() {
if (mediamail.email.value == "")
{
alert("You must enter an e-mail address!");
mediamail.email.focus();
return (false);
}
var okEmail = mediamail.email.value.match(/\b(^(\S+@).+((\.com)|(\.net)|(\.edu)|(\.mil)|(\.gov)|(\.org)|(\..{2,2}))$)\b/gi);
if (okEmail){
ok = true;
} else {
alert('Please enter a valid e-mail address.');
mediamail.email.focus();
mediamail.email.select();
ok = false;
return false;
}
if (mediamail.name.value == ""){
alert("Please enter your full name.");
mediamail.name.focus();
return (false);
}
if(mediamail.phone.value.match(/[^0-9\.]/) || mediamail.phone.value.match(/\..*\./) || mediamail.phone.value.match(/^\.|\.$/)) {
alert ("Please enter your Number correctly - Numbers only"); 
mediamail.phone.focus();
return (false);
}
document.mediamail.submit();
} 
function goPostal(){
	validator();
}
function clearPostal(){
	document.mediamail.reset();
}

function getObject(id) { 
	if (ie4) {
		return document.all[id]; 
	} else { 
	return document.getElementById(id); 
	} 
}

function toggle(link, divId) { 
	var lText = link.innerHTML; 
	var d = getObject(divId);
	
	if (lText == '+') { 
		link.innerHTML = '-'; 
		d.style.display = 'block';
	} else { 
		link.innerHTML = '+'; 
		d.style.display = 'none'; 
	} 
}

function pageLoc(locNam) { 
		document.cookie = 'locNam='+locNam+'';
	//alert(document.cookie);
}

function getCookie(name) {
    var dc = document.cookie;
    var prefix = name + "=";
    var begin = dc.indexOf("; " + prefix);
    if (begin == -1) {
        begin = dc.indexOf(prefix);
        if (begin != 0) return null;
    } else {
        begin += 2;
    }
    var end = document.cookie.indexOf(";", begin);
    if (end == -1) {
        end = dc.length;
    }
    return unescape(dc.substring(begin + prefix.length, end));
}
function rollLogoIn(logoCol){
	document.logoBag.src="images/"+logoCol+".jpg";
}
function rollLogoOut(){
	var locNam = getCookie('locNam');
	document.logoBag.src="images/"+locNam+".jpg";
	//alert(locNam);
}
function alertSize() {
  var myWidth = 0, myHeight = 0;
  if( typeof( window.innerWidth ) == 'number' ) {
    //Non-IE
    myWidth = window.innerWidth;
    myHeight = window.innerHeight;
  } else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
    //IE 6+ in 'standards compliant mode'
    myWidth = document.documentElement.clientWidth;
    myHeight = document.documentElement.clientHeight;
  } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
    //IE 4 compatible
    myWidth = document.body.clientWidth;
    myHeight = document.body.clientHeight;
  }
  btext.style.height = (myHeight-200);
  //window.alert( 'Width = ' + myWidth );
  //window.alert( 'Height = ' + myHeight );
}
function getObject(id) { 
	return document.getElementById(id); 
}

function toggle(link, divId) { 
	var lText = link.innerHTML; 
	//alert(lText);
	var d = getObject(divId);

	if (lText == '+') { 
		link.innerHTML = '-'; 
		d.style.display = 'block';
	} else { 
		link.innerHTML = '+'; 
		d.style.display = 'none'; 
	} 
}
