// user's functions
/*
       function setCookie(c_name,value,expirehours){
            var exdate=new Date();
            exdate.setHours(exdate.getHours()+expirehours);
            document.cookie=c_name+ "=" +encodeURIComponent(value)+
            ((exdate==null) ? "" : ";expires="+exdate.toGMTString());
       }
       function getCookie(c_name){
            if (document.cookie.length>0){
                  c_start=document.cookie.indexOf(c_name + "=");
                  if (c_start!=-1){
                       c_start=c_start + c_name.length+1;
                       c_end=document.cookie.indexOf(";",c_start);
                       if (c_end==-1) c_end=document.cookie.length;
                       return decodeURIComponent(document.cookie.substring(c_start,c_end));
                  }
            }
            return "";
       }
*/
       function AMSTsetHidden(id){
               var oHidden=document.getElementById(id);
               if (oHidden!=null){
                    oHidden.value=getCookie('bannerNum');
               }
       }
       function AMSTsetClient(){
               var url=new String(decodeURI(document.URL));
               var pos=url.indexOf('?recl=');
               if (pos!=-1){
                  //document.getElementById(id).innerHTML=url.substr(pos+5);
                  setCookie('bannerNum', url.substr(pos+6), '/', 364, 8736);
               } else {
                var ref = document.referrer;
                
                if (ref) {

                  if (ref.indexOf('yandex')!=-1) {
                    setCookie('bannerNum', 79370, '/', 364, 8736);
                  }

                  if (ref.indexOf('google')!=-1) {
                    setCookie('bannerNum', 79371, '/', 364, 8736);
                  }

                  if (ref.indexOf('rambler')!=-1) {
                    setCookie('bannerNum', 79372, '/', 364, 8736);
                  }

                  if (ref.indexOf('go.mail')!=-1) {
                    setCookie('bannerNum', 79445, '/', 364, 8736);
                  }

                }

               }

       }

function disable1()
{
  var form = document.forms[0];
  document.contact.select1.disabled = false;
  document.contact.select2.disabled = true;
  
}
function disable2()
{
  var form = document.forms[0];
  document.contact.select1.disabled = true;
  document.contact.select2.disabled = false;
  
}