$(document).ready(function(){

			$("#nav-one li").hover(

				function(){ $("ul", this).fadeIn("fast"); }, 

				function() { } 

			);

	  	if (document.all) {

				$("#nav-one li").hoverClass ("sfHover");

			}

	  });

	  

		$.fn.hoverClass = function(c) {

			return this.each(function(){

				$(this).hover( 

					function() { $(this).addClass(c);  },

					function() { $(this).removeClass(c); }

				);

			});

};	  





var current = null;   // points to the currently selected div



function toggle(elementId)

   {

   if(current != null) {

   current.style.display = "none";   // hide the previous div

   }

   if(elementId == 0)

      {

      return;

      }

   current = document.getElementById(elementId);   // update the current div

   current.style.display = "inline";

}

		

function clearOutDefaultText(obj, defaultValue)
{
	if(obj.value==defaultValue)
		obj.value='';
}



//used for quicksearch
function lookup(inputString) {
		if(inputString.length == 0) {
			// Hide the suggestion box.
			$('#suggestions').hide();
		} else {
			$.post("rpc.php", {queryString: ""+inputString+""}, function(data){
				if(data.length >0) {
					$('#suggestions').show();
					$('#autoSuggestionsList').html(data);
				}
			});
		}
	} // lookup
	
	function fill(thisValue) {
		$('#inputString').val(thisValue);
		setTimeout("$('#suggestions').hide();", 200);
	}
