// JavaScript Document
 
   // place within <SCRIPT> tags in the <HEAD>
   // days: unquoted Number, secured: unquoted true or false, all others: quoted Strings 
   // name & value required
   // if days omitted defaults to Cookie expiring after 1 day
   // if path omitted defaults to '/' or the top level path for the domain
   // if domain omitted defaults to server domain
   // if secured omitted defaults to transmit Cookie to server over any connection
   
   function setCookie(name, value, days, path, domain, secured)
   {      
      var expire = new Date();
      if(!days){
         var days = 365;
      }
      expire.setTime(expire.getTime() + days*24*60*60*1000);
      document.cookie = name + "=" + escape(value) +
      "; expires=" + expire.toUTCString() +
      ((path) ? "; path=" + path : "'/'") +
      ((domain) ? "; domain=" + domain : "") +
      ((secured) ? "; secure" : "");
   //refresh page
location.reload();

}
   

