	//This function will find 'name' in all the browsers and return it's object
    function getObj(name)
	{
	  if (document.getElementById)
		obj=document.getElementById(name);
	  else if (document.all)
		obj=document.all[name];
	  else if (document.layers)
		obj=document.layers[name];
	 return obj;
	}
	function makeHttpRequest(url, callback_function, addReturnVal ,return_xml)
{
 var http_request = false;
 http_request=getAjax();
 
 if (!http_request) {
       //alert('Unfortunatelly you browser doesn\'t support this feature.');
       return false;
 }
 http_request.onreadystatechange = function() 
 {
  if (http_request.readyState == 4) 
  { 
   if (http_request.status == 200) 
   {	
    if(callback_function) 
    { 
	 if(addReturnVal) returns='('+addReturnVal+',';
	 else returns='(';
 	 if (return_xml)  
	 {
	  eval(callback_function + returns+'http_request.responseXML)');
	 } 
	 else 
	 { 
	  eval(callback_function + returns+'http_request.responseText)');
	 }
    }
   }  
   else 
   {
     //alert('There was a problem with the request.(Code: ' + http_request.status + ')');
	// return false;
   }
  }
 }
 http_request.open('GET', url, true);
 http_request.send(null);
 return true;
}

		function getAjax()
		{
   var xmlhttp;
		 if (window.XMLHttpRequest) // Mozilla, Safari,...
			{ 
			 xmlhttp = new XMLHttpRequest();
			 if (xmlhttp.overrideMimeType) 
				   xmlhttp.overrideMimeType('text/html');
		  } 
		 	else if (window.ActiveXObject) // IE
				{ 
			   try 
						{
				   xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
			   } catch (e) 
						{
				   try 
							{
					   xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
				   } catch (e) {}
			   }
		   }            
     return xmlhttp;
    }
	
	 function hightlightRow() {
    // for every table row ...
	var rows = document.getElementsByTagName('span');
	for ( var i = 0; i < rows.length; i++ ) {
	    // ... with the class 'odd' or 'even' ...
		if ( 'hightlight' != rows[i].className) {
		    continue;
		}
	    // ... add event listeners ...
        // ... to highlight the row on mouseover ...
	    if ( navigator.appName == 'Microsoft Internet Explorer' ) {
	        // but only for IE, other browsers are handled by :hover in css
			rows[i].onmouseover = function() {
			    this.className += ' hover'; 
			}
			rows[i].onmouseout = function() {
			    this.className = this.className.replace( ' hover', '' );
			}
	    }
	}
}
window.onload=hightlightRow;

function addCommas(nStr)
{
	nStr += '';
	x = nStr.split('.');
	x1 = x[0];
	x2 = x.length > 1 ? '.' + x[1] : '';
	var rgx = /(\d+)(\d{3})/;
	while (rgx.test(x1)) {
		x1 = x1.replace(rgx, '$1' + ',' + '$2');
	}
	return x1 + x2;
}
