    shown=''
    function help(url) {
    if( shown=='' || shown.closed) {
    	shown=window.open(url,'help','scrollbars=yes,status=no, high,width=200,height=200');
    }
    else{ 
    	shown.close();
    	shown=window.open(url,'help','scrollbars=yes,status=no, high,width=200,height=200');
    }
    }

   function PopupPic(sPicURL) { 
     window.open( "popup.html?"+sPicURL, "",  
     "resizable=1,HEIGHT=200,WIDTH=200,scrollbars=yes,status=no"); 
   } 

<!--
menu_status = new Array(); 
function showHide(theid){
    if (document.getElementById) {
    var switch_id = document.getElementById(theid);
    var button_id = document.getElementById('showit');

        if(menu_status[theid] != 'show') {
           switch_id.className = 'show';
           menu_status[theid] = 'show';
           button_id.className = 'hide';
           document['sign'].src = 'gfx/minus.gif';
        }else{
           switch_id.className = 'hide';
           menu_status[theid] = 'hide';
           button_id.className = 'formbutton';
           document['sign'].src = 'gfx/plus.gif';
        }
    }
}

//-->

<!--
menu_status2 = new Array(); 
function process(theid){
    if (document.getElementById) {
    var switch_id = document.getElementById(theid);

        if(menu_status2[theid] != 'show') {
           switch_id.className = 'show';
           menu_status2[theid] = 'show';
        }else{
           switch_id.className = 'hide';
           menu_status2[theid] = 'hide';
        }
    }
    setTimeout('document.images["bar"].src = "gfx/loading.gif"', 200); 
    
}

//-->

<!--
menu_status3 = new Array(); 
function qprocess(theid){
    if (document.getElementById) {
    var switch_id = document.getElementById(theid);

        if(menu_status3[theid] != 'show') {
           switch_id.className = 'show';
           menu_status3[theid] = 'show';
        }else{
           switch_id.className = 'hide';
           menu_status3[theid] = 'hide';
        }
    }
    
}

//-->

function createRequestObject() {
    var ro;
    var browser = navigator.appName;
    if(browser == "Microsoft Internet Explorer"){
        ro = new ActiveXObject("Microsoft.XMLHTTP");
    }else{
        ro = new XMLHttpRequest();
    }
    return ro;
}

var http = createRequestObject();

function sendemail() {
	var msg = document.contactform.msg.value;
	var name = document.contactform.name.value;
	var email = document.contactform.email.value;
	var subject = document.contactform.subject.value;
	document.contactform.send.disabled=true;
	document.contactform.send.value='Sending....';

	http.open('POST', 'contact.php','true');
	http.onreadystatechange = handleResponse;
	// force no-cache so browser always makes request and doesn't use cache'd results
	http.setRequestHeader("If-Modified-Since", "Sat, 1 Jan 2000 00:00:00 GMT");
	// tell server this is a form submission
	http.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
	http.send('msg='+msg+'&name='+name+'&subject='+subject+'&email='+email+'&action=send');

}

function handleResponse() {
    if(http.readyState == 4){
        var response = http.responseText;
        var update = new Array();

        if(response.indexOf('|' != -1)) {
            update = response.split('|');
            document.getElementById(update[0]).innerHTML = update[1];

        }
    }
}

function popUp(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=780,height=431');");
}

function echeck(str) {

		var at="@"
		var dot="."
		var lat=str.indexOf(at)
		var lstr=str.length
		var ldot=str.indexOf(dot)
		if (str.indexOf(at)==-1){
		   alert("Invalid E-mail ID")
		   return false
		}

		if (str.indexOf(at)==-1 || str.indexOf(at)==0 || str.indexOf(at)==lstr){
		   alert("Invalid E-mail ID")
		   return false
		}

		if (str.indexOf(dot)==-1 || str.indexOf(dot)==0 || str.indexOf(dot)==lstr){
		    alert("Invalid E-mail ID")
		    return false
		}

		 if (str.indexOf(at,(lat+1))!=-1){
		    alert("Invalid E-mail ID")
		    return false
		 }

		 if (str.substring(lat-1,lat)==dot || str.substring(lat+1,lat+2)==dot){
		    alert("Invalid E-mail ID")
		    return false
		 }

		 if (str.indexOf(dot,(lat+2))==-1){
		    alert("Invalid E-mail ID")
		    return false
		 }
		
		 if (str.indexOf(" ")!=-1){
		    alert("Invalid E-mail ID")
		    return false
		 }

 		 return true					
	}

function ValidateForm(){
	var emailID=document.formhost.email
	
	if ((emailID.value==null)||(emailID.value=="")){
		alert("Please enter your e-mail address.")
		emailID.focus()
		return false
	}
	if (echeck(emailID.value)==false){
		emailID.value=""
		emailID.focus()
		return false
	}
	document.formhost.hostit.disabled = true;
	return true
 }

function xmlhttpPost(strURL) {
if(ValidateForm()){
    var xmlHttpReq = false;
    var self = this;
    // Mozilla/Safari
    if (window.XMLHttpRequest) {
        self.xmlHttpReq = new XMLHttpRequest();
    }
    // IE
    else if (window.ActiveXObject) {
        self.xmlHttpReq = new ActiveXObject("Microsoft.XMLHTTP");
    }
    self.xmlHttpReq.open('POST', strURL, true);
    self.xmlHttpReq.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
    self.xmlHttpReq.onreadystatechange = function() {
        if (self.xmlHttpReq.readyState == 4) {
            updatepage(self.xmlHttpReq.responseText);
        }
    }
    self.xmlHttpReq.send(getquerystring());
}
}

function getquerystring() {
    var form     = document.forms['formhost'];
    var emailaddy = form.email.value;
    var encryptee = form.i.value;
    qstr = 'i=' + encodeURIComponent(encryptee) + '&email=' + escape(emailaddy);  // NOTE: no '?' before querystring
    return qstr;
}

function updatepage(str){
    document.getElementById("hostitresult").innerHTML = str;
}

var sec = 59;   // set the seconds
var min = 29;   // set the minutes

function countDown() {
   sec--;
  if (sec == -01) {
   sec = 59;
   min = min - 1; }
  else {
   min = min; }

if (sec<=9) { sec = "0" + sec; }

  time = (min<=9 ? "0" + min : min) + ":" + sec + " minut";

if (document.getElementById) { document.getElementById('theTime').innerHTML = time; }

SD=window.setTimeout("countDown();", 1000);
if (min == '00' && sec == '00') { sec = "00"; window.clearTimeout(SD); }
}


