
function setFormAction(form,action) {
	try {
		form.setAttribute('action') = action;
	}
	catch(e) {
		form.action = action;
	}
}


function getFormAction(form) {
      try {
			return form.getAttribute('action');
      }
      catch(e) {
			return form.action;
      }
}



function setCookie(name, value, expires, path, domain, secure)
{
    document.cookie= name + "=" + escape(value) +
        ((expires) ? "; expires=" + expires.toGMTString() : "") +
        ((path) ? "; path=" + path : "; path=/") +
        ((domain) ? "; domain=" + domain : "") +
        ((secure) ? "; secure" : "");
}

function setPermCookie(name, value, path, domain, secure) {
	var expires;
/*	DISABLED -- GOV WEB SITES DO NOT ALLOW PERMANENT COOKIES
	var expires = new Date();
	expires.setFullYear(expires.getFullYear()+1000);
*/
	setCookie(name, value, expires, domain, secure);
}

function getCookie(name)
{
    var dc = document.cookie;
    var prefix = name + "=";
    var begin = dc.indexOf("; " + prefix);
    if (begin == -1)
    {
        begin = dc.indexOf(prefix);
        if (begin != 0) return null;
    }
    else
    {
        begin += 2;
    }
    var end = document.cookie.indexOf(";", begin);
    if (end == -1)
    {
        end = dc.length;
    }
    return unescape(dc.substring(begin + prefix.length, end));
}

function deleteCookie(name, path, domain)
{
    if (getCookie(name))
    {
        document.cookie = name + "=" + 
            ((path) ? "; path=" + path : "; path=/") +
            ((domain) ? "; domain=" + domain : "") +
            "; expires=Thu, 01-Jan-70 00:00:01 GMT";
    }
}


setCookie('test',true);

/*
function heightCheck() {
var hc_top;

	if (document.getElementById('js_hc') != undefined) {
		hc_top = document.getElementById('js_hc').offsetTop;
		if (hc_top < minheight) {
			if (document.getElementById('js_hc_filler') != undefined) {
				document.getElementById('js_hc_filler').style.height = (minheight - hc_top) + 'px';
			}
		}
	}

}

*/
