function showimg(k){
	if (!document.getElementById) return;
	obj = document.getElementById(k);
	newImage = "url(/images/nav-blue-on.gif) no-repeat 50% bottom";
	obj.style.background = newImage;
}

function hideimg(k){
	if (!document.getElementById) return;
	obj = document.getElementById(k);
	newImage = "";
	obj.style.background = newImage;
}

try {
	document.execCommand("BackgroundImageCache", false, true);
} catch(err) {}


function set_cookie ( name, value, expires_year, expires_month, expires_day, path, domain, secure )
{ 
  var cookie_string = name + "=" + escape ( value );

  if ( expires_year )
  {
    var expires = new Date ( expires_year, expires_month, expires_day );
    expires.setTime((new Date()).getTime()+3000);
    cookie_string += "; expires=" + expires.toGMTString();
  }

  if ( path )
	cookie_string += "; path=" + escape ( path );
  if ( domain )
	cookie_string += "; domain=" + escape ( domain );

  if ( secure )
	cookie_string += "; secure";
  document.cookie = cookie_string;
}

function delete_cookie(cookie_name)
{
  var cookie_date = new Date ( ); 
  var date2 = new Date ( );
//  cookie_date.setDate(cookie_date.getDate()-100);
//  cookie_date.setTime ( (new Date().getTime()) -100000 );
 // document.cookie = cookie_name += "=; expires=" + cookie_date.toGMTString();

}

function get_cookie ( cookie_name )
{
  var results = document.cookie.match ( '(^|;) ?' + cookie_name + '=([^;]*)(;|$)' );

  if ( results )
    return ( unescape ( results[2] ) );
  else
    return null;
}

function setMemo(section){
    var current_date = new Date;
    var cookie_year = current_date.getFullYear ( ); 
    var cookie_month = current_date.getMonth ( );
    var cookie_day = current_date.getDate ( );
    set_cookie ( "section", section, cookie_year, cookie_month, cookie_day );
}
