function combine(){
var delimiter, numArgs, combination, i;
combination="";
delimiter="|";
numArgs=combine.arguments.length;
if (numArgs>1) {
    for (i=0; i<numArgs; i++) {
	combination=combination+combine.arguments[i]+delimiter;
    }
}

return combination.substring(0, combination.length-1);
}

function breakdown(combination){
var delimiter, start, end, count;
broken=new Object();
delimiter="|";
start=end=0;
count=1;
end=combination.indexOf(delimiter,end)
while ((end) && (end>-1)){
    broken[count]=combination.substring(start,end);
    count++;
    start=end+1;  
    end=combination.indexOf(delimiter,start) 
}
broken[count]=combination.substring(start,combination.length);
broken[0]=count+1;
return broken;
}

function ReadCookie(name){
var allCookie, CookieVal, length,start,end;
cookieVal="";
name=name+"=";  //append equals to avoid false matches.
allCookie=document.cookie;
length=allCookie.length;
if (length>0) {//no cookies - user is probably incinerating cookies.
    start=allCookie.indexOf(name,0)
    if (start!=-1) {//if string appeared - otherwise cookie wasn't set.
	start+=name.length;
	end=allCookie.indexOf(";",start);
	if (end==-1) {end=length;}
	cookieVal=unescape(allCookie.substring(start,end));
    }
}
return(cookieVal);
}

function wCook(name, value, hours)
{
  var expire = "";
  if(hours != null)
  {
    expire = new Date((new Date()).getTime() + hours * 3600000);
    expire = "; expires=" + expire.toGMTString();
  }
  document.cookie = name + "=" + escape(value) + expire;
}
function readCookie(name)
{
  var cookieValue = "";
  var search = name + "=";
  if(document.cookie.length > 1)

  { 
  
    offset = document.cookie.indexOf(search);
    if (offset != -1)
	
 	//url = 'login.asp';  window.location.href = url;
	
	
    { 
      offset += search.length;
      end = document.cookie.indexOf(";", offset);
      if (end == -1) end = document.cookie.length;
      cookieValue = unescape(document.cookie.substring(offset, end))
    }
  }
  return cookieValue; 
}
function deleteCookie(name)

{ 
    if (readCookie(name)) document.cookie = name + "=" +
       ( (path) ? ";path=" + path : "") +
       ( (domain) ? ";domain=" + domain : "") +
       ";expires=Thu, 01-Jan-70 00:00:01 GMT";
	 }
	 
hcs = readCookie("hcs");
	function get(){
	if(document.cookie.length < 1){
			document.searchform.className='on';
			//document.discform.className='on';
			 }	
			if (hcs =="yes"){
				myResume();
				}
				if (hcs=="ownername"){
					myResume();
					document.searchform.className='on';
					document.searchform.owner.focus();
					document.addressform.className='off';
					document.folioform.className='off';
					document.pinform.className='off';
					document.tgownerform.className='off';
					document.tgaddform.className='off';
					document.tgfolioform.className='off';
					
					}
				if (hcs=="strname"){
					myResume();
					document.searchform.className='off';
					document.folioform.className='off';
					document.pinform.className='off';
					document.tgownerform.className='off';
					document.tgaddform.className='off';
					document.tgfolioform.className='off';
					document.addressform.className='on';
					//document.addressform.str_num_from.focus();
					}
					if (hcs=="folio"){
						myResume();
						document.searchform.className='off';
						document.addressform.className='off';
						document.folioform.className='on';
						document.folioform.folio1.focus();
						document.pinform.className='off';
						document.tgownerform.className='off';
						document.tgaddform.className='off';
						document.tgfolioform.className='off';
						}						
						if (hcs=="pin"){
							myResume();
							document.searchform.className='off';
							document.addressform.className='off';
							document.folioform.className='off';
							document.pinform.className='on';
							document.pinform.section.focus();
							document.tgownerform.className='off';
							document.tgaddform.className='off';
							document.tgfolioform.className='off';
						}
						//tangible owner cook
							if (hcs=="town"){
								myResume();
								document.searchform.className='off';
								document.addressform.className='off';
								document.folioform.className='off';
								document.pinform.className='off';
								document.tgownerform.className='on';
								document.tgownerform.owner.focus();
								document.tgaddform.className='off';
								document.tgfolioform.className='off';
							}
							//tang address cook
								if (hcs=="tadd"){
									myResume();
									document.searchform.className='off';
									document.addressform.className='off';
									document.folioform.className='off';
									document.pinform.className='off';
									document.tgownerform.className='off';
									document.tgaddform.className='on';
									document.tgaddform.str_num_from.focus();
									document.tgfolioform.className='off';
							}
							//tang folio cook
								if (hcs=="tfol"){
										myResume();
										document.searchform.className='off';
										document.addressform.className='off';
										document.folioform.className='off';
										document.pinform.className='off';
										document.tgownerform.className='off';
										document.tgaddform.className='off';
										document.tgfolioform.className='on';
										document.tgfolioform.acct1.focus();
										}
							
					
			}
			
function activateSearch(){
      get();


}
function hCook(){
document.addressform.className='off';
document.searchform.className='off';
document.folioform.className='off';
document.pinform.className='off';
document.tgownerform.className='off';
document.tgaddform.className='off';
document.tgfolioform.className='off';
}

// zeusdidit .. added cookie stuff to this one page.
