﻿function contactPopup() {
    mywindow = window.open("http://formdu.com/contactform.aspx?id=1312&rand=v1kP4",
            "mywindow", "location=1,status=1,scrollbars=1,width=850px,height=650px");
}
function showScreenshots(query) {
    mywindow = window.open("screenshot.aspx?q="+query,
            "mywindow", "location=1,status=1,scrollbars=1,width=800px,height=700px");
}   
function selectText(id)
{
    document.getElementById(id).focus();
    document.getElementById(id).select();
}     
function showhelp() {
    window.open('TrackerListHelp.htm','tlh','status=0,toolbar=0,location=0,menubar=0,resizable=0,scrollbars=1,height=500,width=500');
    return true;
}
function showCLDisclaimer() {
    window.open('clghosting.aspx','tlh','status=0,toolbar=0,location=0,menubar=0,resizable=0,scrollbars=1,height=500,width=500');
    return true;
}
var x=0,y = 0;
function showMP( c, id )
{
    var e = document.getElementById(id);
    if( c == 1 )
    {
        if( !x )
        {
            var oElement = document.getElementById(id+'tag');                
            while( oElement != null ) {
                y += oElement.offsetTop;
                x += oElement.offsetLeft;
                oElement = oElement.offsetParent;
            }
            e.style.left = x + 'px';
        }               
        e.style.visibility = 'visible';
    }
    else 
    {
         e.style.visibility = 'hidden';
    }
}
function closeMsg(msgBoxId, msgId)
{
    document.getElementById(msgBoxId).style.display='none';
    var xmlhttp;
    if (window.XMLHttpRequest) {// code for IE7+, Firefox, Chrome, Opera, Safari
		xmlhttp = new XMLHttpRequest();
	}
	else {// code for IE6, IE5
		xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
	}
	xmlhttp.open('GET', "ajaxcallback.ashx?action=closemsg&msgid="+msgId, true);
	xmlhttp.onreadystatechange = function() {}
	xmlhttp.send();
}
