	 
    function copy(text2copy) {
      if (window.clipboardData) {
        window.clipboardData.setData("Text",text2copy);
      } else {
        var flashcopier = 'flashcopier';
        if(!document.getElementById(flashcopier)) {
          var divholder = document.createElement('div');
          divholder.id = flashcopier;
          document.body.appendChild(divholder);
        }
        document.getElementById(flashcopier).innerHTML = '';
        var divinfo = '<embed src="_clipboard.swf" FlashVars="clipboard='+escape(text2copy)+'" width="0" height="0" type="application/x-shockwave-flash"></embed>';
        document.getElementById(flashcopier).innerHTML = divinfo;
      }
    }
    
    function doAccent(object) {
      if(!$(object).hasClass("accent")) {
        $(object).addClass("accent");
      }
    }
    
    function undoAccent(object) {
      if($(object).hasClass("accent")) {
        $(object).removeClass("accent");
      }
    }
    
    function check(object) {
      $(object).blur();
      var cbox = 'null';
      if($(object).is(':checkbox'))
      	cbox = object;
      else if($(object).prev().is(':checkbox'))
      	cbox = $(object).prev();
      else if($(object).next().is(':checkbox'))
      	cbox = $(object).next();
      else if($('input:checkbox', object).length)
      	cbox = $('input:checkbox:first', object);
      else if($('input:checkbox', $(object).prev()).length)
        cbox = $('input:checkbox:first', $(object).prev());
      else if($('input:checkbox', $(object).next()).length)
        cbox = $('input:checkbox:first', $(object).next());

      if(cbox != 'null') {   		
        if($(cbox).is(':checked')){
          $(cbox).removeAttr('checked');
        } else {
          $(cbox).attr('checked','checked');
        }
        return;
      }
      
      
      var radio = 'null';
      if($(object).is(':radio'))
      	radio = object;
      else if($(object).prev().is(':radio'))
      	radio = $(object).prev();
      else if($(object).next().is(':radio'))
      	radio = $(object).next();
      else if($('input:radio', object).length)
      	radio = $('input:radio:first', object);
      else if($('input:radio', $(object).prev()).length)
        radio = $('input:radio:first', $(object).prev());
      else if($('input:radio', $(object).next()).length)
        radio = $('input:radio:first', $(object).next());

      if(radio != 'null') {   		
        if(!$(radio).is(':checked')){
          $(radio).attr('checked','checked');
        }
        return;
      }
    }
    
    $(document).ready(
      function() {
        $('a > img, a > span.button').parent().addClass('noline');
        $(':checkbox, :radio').addClass('nostyle');
        $(':input, :submit, span.button').not(':checkbox, select').focus(function(){doAccent(this);});
        $(':input, :submit, span.button').not(':checkbox, select').blur(function(){undoAccent(this);});
        $('input:checkbox').checkbox();
      }
    );
    
    function setCookie(c_name,value,expiredays) {
      var exdate=new Date();
      exdate.setDate(exdate.getDate()+expiredays);
      document.cookie=c_name+ "=" +escape(value)+
        ((expiredays==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 unescape(document.cookie.substring(c_start,c_end));
        } 
      }
      return "";
    }
    
    function ReturnGlobal(response) {
      eval(response);
    }
    
//    $(function(){$.each($("td"), function(){$(this).css('text-align', $(this).attr('align'));});});
