

function clr_clipboard() {
    if(!document.body) {
	setTimeout('clr_clipboard()',300);
	return;
    }

    //alert('here'); 

    var hpta=document.getElementById('hp_ta');
    if (hpta!=null && hpta.createTextRange!=null) {
            hpta.createTextRange().execCommand("Copy");
            setTimeout('clr_clipboard()',300);
} else {

    var flashcopier = 'flashcopier';
    if(!document.getElementById(flashcopier)) {
    
      divholder = document.createElement('div');
      divholder.id = flashcopier;
      document.body.appendChild(divholder);
    
    }
    
    var divinfo = '<embed src="/clipb_cln.swf" FlashVars="clipboard='+escape(' ')+'" width="0" height="0" type="application/x-shockwave-flash"></embed>';
    document.getElementById(flashcopier).innerHTML = divinfo;
    
  }
}


function hp_ne()
{
  return true
}

function hp_ndd()
{
  return false;
}



//if(navigator.appName.indexOf('Internet Explorer')==-1||(navigator.userAgent.indexOf('MSIE')!=-1 && document.all.length!=0))
//{
//  if(document.all && navigator.userAgent.indexOf('Opera')==-1 && navigator.userAgent.indexOf('MSIE 7.')==-1)
//  {
//    if (document.all && !window.opera && window.XMLHttpRequest) document.write('<div style="position:absolute;left:-2000px;top:-2000px"><input type="textarea" name="hp_ta" value=" " style="visibility:hidden"></div>');
//    clr_clipboard();
//  }
//}

function print_dis() {
	if(navigator.appName.indexOf('Internet Explorer')==-1||(navigator.userAgent.indexOf('MSIE')!=-1 && document.all.length!=0)) {
	  if(document.all && navigator.userAgent.indexOf('Opera')==-1 && navigator.userAgent.indexOf('MSIE 7.')==-1) {
	    if (document.all && !window.opera && window.XMLHttpRequest) document.write('<div style="position:absolute;left:-2000px;top:-2000px"><input type="textarea" name="hp_ta" value=" " style="visibility:hidden"></div>');
		    clr_clipboard();
	  }
	}





	onerror=hp_ne;

	document.ondragstart=hp_ndd;

	setTimeout("clr_clipboard()", 30);

	function p1(){for(var pp=0;pp<document.all.length;pp++){if(document.all[pp].style.visibility!='hidden'){document.all[pp].style.visibility='hidden';document.all[pp].id='ph'}}}function p2(){for (pp=0;pp<document.all.length;pp++){if(document.all[pp].id=='ph')document.all[pp].style.visibility=''}}window.onbeforeprint=p1;window.onafterprint=p2;
	//alert('on');
}
