


timerID = null;
var active = 0;

/*function ChangePage(num){
    if(document.getElementById){
    obj[active].style.visibility = "hidden"
    active = num
    obj[active].style.top = 0;
    obj[active].style.visibility = "visible"
    }
}

function ScrollUp(speed){
if(document.getElementById){
    if(parseInt(obj[active].style.top) < 0)
    obj[active].style.top = parseInt(obj[active].style.top) + speed + "px";
    timerID = setTimeout("ScrollUp("+speed+")",30)
    }
}


function ScrollDown(speed){
    if(document.getElementById){                        
    if(parseInt(obj[active].style.top) > 
    document.getElementById('cont').offsetHeight - obj[active].offsetHeight) 
    obj[active].style.top = parseInt(obj[active].style.top) - speed + "px";
    timerID = setTimeout("ScrollDown("+speed+")",30)
    }
}

function PScrollDown(speed){
    if(document.getElementById){                        
    if(parseInt(obj[active].style.top) > 
    document.getElementById('p_cont').offsetHeight - obj[active].offsetHeight) 
    obj[active].style.top = parseInt(obj[active].style.top) - speed + "px";
    timerID = setTimeout("PScrollDown("+speed+")",30)
    }
}

function ScrollStop(){
    if(document.getElementById){
    clearTimeout(timerID);
    }
}

function ScrollPageInit() {
    if(document.getElementById){
    obj = document.getElementById("cont").getElementsByTagName("div");
    obj['page1'].style.visibility = "visible";
    obj['page1'].style.top = 0;	
    }	
    if(document.addEventListener){
    for(i=0;i<document.getElementsByTagName('a').length;i++) 
    document.getElementsByTagName('a')[i].style.position = "relative";
    }
}

function PScrollPageInit() {
    if(document.getElementById){
    obj = document.getElementById("p_cont").getElementsByTagName("div");
    obj['page2'].style.visibility = "visible";
    obj['page2'].style.top = 0;	
    }	
    if(document.addEventListener){
    for(i=0;i<document.getElementsByTagName('a').length;i++) 
    document.getElementsByTagName('a')[i].style.position = "relative";
    }
}

*/
function ScrollUp(speed){
    	if(document.getElementById){
        	if(parseInt(txt.style.top) < 0){
        		txt.style.top = parseInt(txt.style.top) + speed + "px";
		}
        	timerID = setTimeout("ScrollUp("+speed+")",30)
    	}
}

function ScrollDown(speed){
   	if(document.getElementById){                        
        	if(parseInt(txt.style.top) > cnt.offsetHeight - txt.offsetHeight){ 
        		txt.style.top = parseInt(txt.style.top) - speed + "px";
		}
        	timerID = setTimeout("ScrollDown("+speed+")",30)
    	}
}


function PScrollDown(speed){
    	if(document.getElementById){                        
        	if(parseInt(txt.style.top) > cnt.offsetHeight - txt.offsetHeight){ 
        		txt.style.top = parseInt(txt.style.top) - speed + "px";
		}
        	timerID = setTimeout("PScrollDown("+speed+")",30)
    	}
}

function ScrollStop(){
    	if(document.getElementById){
        	clearTimeout(timerID);
    	}
}

function ScrollInit() {
	if (document.getElementById) {
        	cnt = document.getElementById("cont");
        	txt = document.getElementById("text");
        	txt.style.top = 0;
    	}
}

function PScrollInit() {
   	if (document.getElementById) {
        	cnt = document.getElementById("p_cont");
        	txt = document.getElementById("p_text");
        	txt.style.top = 0;
    	}
}


function send() {
    document.login.submit();
}


function popup(str) {
  if (navigator.appVersion.indexOf ("Macintosh") >=0) {
    window.open (str, "bebsoftware",
      "width=550,height=400,resizable=1,location=no,status=no,menubar=no,scrollbars=yes,toolbar=no")
  } else {
    window.open (str, "bebsoftware",
      "width=550,height=400,resizable=1,location=no,status=no,menubar=no,scrollbars=no,toolbar=no,dependent=no")
  }
}

