   function highlightOn(elem) {
            elem.className="menuOn";
   }

   function highlightOff(elem) {
            elem.className="menuOff";
   }

   function HighlightSelection(elem) {
            elem.className="LightOn";
   }

   function UnHighlightSelection(elem) {
            elem.className="LightOff";
   }

   var yeni = null;
   function popup(a,b,c) {
			var en = (b == 0) ? 300 : ((b < 100) ? 100 : ((b > 800) ? 800 : b));
			var boy = (c == 0) ? 300 : ((c < 100) ? 100 : ((c > 600) ? 600 : c));
			if(yeni == null || yeni.closed) {
			  yeni=window.open(a,"outputWindow","left=100,top=100,menubar=yes,scrollbars=yes,resizable=yes,width="+en+",height="+boy);
			} else {
			  window.yeni.location=a;
			}
			if(navigator.appName == "Microsoft Internet Explorer" &&
			  parseInt(navigator.appVersion) >= 4) {
			      yeni.focus();
			} else {
			    if(navigator.appName != "Microsoft Internet Explorer")
			       yeni.focus(); 
		    }
   }

   
//------------------------------------------------------------------------------------
//---------------------------------PRINT FUNCTIONS BEGIN------------------------------
//------------------------------------------------------------------------------------
var intNumberofAlreadyHiddenElements = 0 ;
var ArrayofHiddenElementNames = new Array();

//------------------------------------------------------------------------------
function ElementwasHiddenBeforePrint(Elementname) {

	for (var i=0;i < intNumberofAlreadyHiddenElements;i++){
	    if ( ArrayofHiddenElementNames[i] == Elementname)
	       return ( true );
	} /* for */

	return (false);
}
//------------------------------------------------------------------------------

//------------------------------------------------------------------------------
function HideUnPrintableElemets() {
      intNumberofAlreadyHiddenElements = 0 ;

      var coll = document.all;

      if (coll!=null) {
         for (var i=0; i<coll.length; i++) {
            if ( coll[i].printable != null ) {
                if ( coll[i].printable == "0" ) {
                   if ( coll[i].name != null && coll[i].name != '' ) {
                      // if this element is already hidden from the browser make note of it
                      // so that when it is time to show elements, this element is not shown.
                      if ( coll[i].style.display == 'none' ) {
                         ArrayofHiddenElementNames[intNumberofAlreadyHiddenElements] = coll[i].name ;
                         intNumberofAlreadyHiddenElements++;
                      }
                   }

                   coll[i].style.display='none';
                }
            }
        } /* for */
     } /* if */

} /* function HideUnPrintableElemets() */
//------------------------------------------------------------------------------

//------------------------------------------------------------------------------
function ShowUnPrintableElemets() {

      var coll = document.all;

      if (coll!=null) {
        for (i=0; i<coll.length; i++) {
            if ( coll[i].printable != null) {
                if ( coll[i].printable == "0" ) {
                   if ( coll[i].name != null && coll[i].name != '' ) {
                      // show this element only if this element was not already hidden from the browser
                      if ( ! ElementwasHiddenBeforePrint(coll[i].name) ) {
                         coll[i].style.display='';
                      }
                   }
                   else
                      coll[i].style.display='';
                } /* if */
             } /* if */
        } /* for */
    } /* if */

} /* function ShowUnPrintableElemets() */
//------------------------------------------------------------------------------


//------------------------------------------------------------------------------------
//---------------------------------PRINT FUNCTIONS END--------------------------------
//------------------------------------------------------------------------------------



//------------------------------------------------------------------------------------
//-------------------------------BROWSER VERSION BEGIN--------------------------------
//------------------------------------------------------------------------------------

    // Note: On IE5, these return 4, so use is_ie5up to detect IE5.
	var agt = navigator.userAgent.toLowerCase();
	
    var is_major = parseInt(navigator.appVersion);
    var is_minor = parseFloat(navigator.appVersion);

    // Note: Opera and WebTV spoof Navigator.  We do strict client detection.
    // If you want to allow spoofing, take out the tests for opera and webtv.
    var is_nav  = ((agt.indexOf('mozilla')!=-1) && (agt.indexOf('spoofer')==-1)
                && (agt.indexOf('compatible') == -1) && (agt.indexOf('opera')==-1)
                && (agt.indexOf('webtv')==-1) && (agt.indexOf('hotjava')==-1));
    var is_nav2 = (is_nav && (is_major == 2));
    var is_nav3 = (is_nav && (is_major == 3));
    var is_nav4 = (is_nav && (is_major == 4));
    var is_nav4up = (is_nav && (is_major >= 4));
    var is_navonly      = (is_nav && ((agt.indexOf(";nav") != -1) ||
                          (agt.indexOf("; nav") != -1)) );
    var is_nav6 = (is_nav && (is_major == 5));
    var is_nav6up = (is_nav && (is_major >= 5));
    var is_gecko = (agt.indexOf('gecko') != -1);


    var is_ie     = ((agt.indexOf("msie") != -1) && (agt.indexOf("opera") == -1));
    var is_ie3    = (is_ie && (is_major < 4));
    var is_ie4    = (is_ie && (is_major == 4) && (agt.indexOf("msie 4")!=-1) );
    var is_ie4up  = (is_ie && (is_major >= 4));
    var is_ie5    = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.0")!=-1) );
    var is_ie5_5  = (is_ie && (is_major == 4) && (agt.indexOf("msie 5.5") !=-1));
    var is_ie5up  = (is_ie && !is_ie3 && !is_ie4);
    var is_ie5_5up =(is_ie && !is_ie3 && !is_ie4 && !is_ie5);
    var is_ie6    = (is_ie && (is_major == 4) && (agt.indexOf("msie 6.")!=-1) );
    var is_ie6up  = (is_ie && !is_ie3 && !is_ie4 && !is_ie5 && !is_ie5_5);

//------------------------------------------------------------------------------------
//--------------------------------BROWSER VERSION END---------------------------------
//------------------------------------------------------------------------------------
function set_page_title(strtitle) {
	 if (!document.getElementById) return;
	 document.getElementById('pagetitle').innerHTML = strtitle;
	 document.title = strtitle;
}
//------------------------------------------------------------------
function CCA(CB){
    if (CB.checked)
       hL(CB);
    else
       dL(CB);
}
function hL(E){
     if (is_ie5_5up)
       while (E.tagName!="TR") E=E.parentElement;
     else
       while (E.tagName!="TR") E=E.parentNode;
     E.className = "highlightedrow";
}
function dL(E){
    if (is_ie5_5up)
       while (E.tagName!="TR") E=E.parentElement;
    else
       while (E.tagName!="TR") E=E.parentNode;
    E.className = "";
}
//------------------------------------------------------------------
//result = trim(inputString);
function trim(inputString) {
   // Removes leading and trailing spaces from the passed string. Also removes
   // consecutive spaces and replaces it with one space. If something besides
   // a string is passed in (null, custom object, etc.) then return the input.
   if (typeof inputString != "string") { return inputString; }
   var retValue = inputString;
   var ch = retValue.substring(0, 1);
   while (ch == " ") { // Check for spaces at the beginning of the string
      retValue = retValue.substring(1, retValue.length);
      ch = retValue.substring(0, 1);
   }
   ch = retValue.substring(retValue.length-1, retValue.length);
   while (ch == " ") { // Check for spaces at the end of the string
      retValue = retValue.substring(0, retValue.length-1);
      ch = retValue.substring(retValue.length-1, retValue.length);
   }
//   while (retValue.indexOf("  ") != -1) { // Note that there are two spaces in the string - look for multiple spaces within the string
//      retValue = retValue.substring(0, retValue.indexOf("  ")) + retValue.substring(retValue.indexOf("  ")+1, retValue.length); // Again, there are two spaces in each of the strings
//   }
   return retValue; // Return the trimmed string back to the user
} // Ends the "trim" function
//------------------------------------------------------------------