	
	function ajaxRequestGET(url,data,div) {
	var aj = new Ajax.Request(  
	url, {   
	method:'get',  
    evalScripts:true,  
	parameters: data+'&sid='+Math.random(),
	onComplete: function(request){ 
	evalResponse(request,div);
	} } );  
	}  
	
	function ajaxRequestPOST(url,data,div) {
	var aj = new Ajax.Request(  
	url, {   
	method:'post',   
    evalScripts:true, 
	parameters: data+'&sid='+Math.random(),
	onComplete: function(request){ 
	evalResponse(request,div);	
	} } );  
	} 
	
	function ajaxRequestPeriodicalGET(url,data,div,freq,dec)
	{
   
  	 new Ajax.PeriodicalUpdater(div, url, {
     method: 'get', frequency: freq, decay: dec,
	 parameters: '&sid='+Math.random(),
   	});
 
	}


		
	
	function evalResponse(oReq,div) {
	$(div).innerHTML = oReq.responseText;
	oReq.responseText.evalScripts();
	/*
	if (oReq.responseText.indexOf(" you are logged in!") != -1) {
		
	window.location='http://spitfire.net/hackers/home';
 
	}*/
	}
		
	function enter_pressed(e){
var keycode;
if (window.event) keycode = window.event.keyCode; 
else if (e) keycode = e.which; 
else return false; 
return (keycode == 13); 
}

