function openthesiswin2(thesisid,thesistype,thesisname,pagefrom,pagenum,thesisClass,catalogId,pagetype,baseurlA)
{
  if (catalogId=="null") catalogId="";
  var baseurl="";
  if (baseurlA){	//default baseurlA=""  
	  var pos = baseurlA.lastIndexOf('/');	  
	  if (pos==baseurlA.length-1)
		  baseurl=baseurlA.substring(0,baseurlA.length-1);
	  else	  
	      baseurl = baseurlA;
 }
  var w,h;
  var pdfname="/files/common/thesis/thesis.html?catalog_id=";
  var posbig5=pdfname.lastIndexOf("gate/big5/");
  if (posbig5>0){
	  pdfname="_____/files/common/thesis/thesis.html?catalog_id=";
	  pdfname = pdfname.replace("_____","");
  }
  if (!thesisClass) thesisClass=1;
  if (thesisClass==1||thesisClass==0) {  //thesisClass 0:thesis，1:zhuan zhu 2:catalog 3:book  //thesistype: -1 empty, 0-text，1-pbs[have catalog]，2-pbs[have not catalog]
   w=window.screen.availWidth-80;
   h=window.screen.availHeight-90;
   //pdfname="/files/common/thesis/thesis.html?catalog_id=";
   if (!pagetype) pagetype="";    //pagetype : T or B or Y
   if (pagetype.length>1) pagetype="";
   var url=baseurl+pdfname + catalogId +'&thesistype='+thesistype+'&thesisname='+encodeURI(thesisname)+'&pagefrom='+pagefrom+'&pagenum='+pagenum+'&pagetype='+pagetype;
   if (!catalogId){//
   	var req={"map":{"psMap":{map:{'method':'A','thesisid':thesisid},"javaClass":"java.util.HashMap"},"SN":"RPHandle"},"javaClass":"java.util.HashMap"};
	jsonrpc.BH.handle(function(rd){
		catalogId = rd[0][0];	
       //pdfname="/files/common/thesis/thesis.html?catalog_id=";
       url=baseurl+pdfname + catalogId +'&thesistype='+thesistype+'&thesisname='+encodeURI(thesisname)+'&pagefrom='+pagefrom+'&pagenum='+pagenum+'&pagetype='+pagetype;       
       window.open(url,'_blank',
    		   "top=40,left=40,toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=no,resizable=yes,width=" +w + ",height=" +h);       
   	},[req]); 	
   }else{	   
	   //alert(url);
	   window.open(url,'_blank',
    		   "top=40,left=40,toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=no,resizable=yes,width=" +w + ",height=" +h);
   }
    
  }else if (thesisClass==3){
	   //book
   w=window.screen.availWidth-80;
   h=window.screen.availHeight-90;
   //pdfname="/files/common/thesis/thesis.html?catalog_id=";
   var url=baseurl+pdfname + catalogId +'&thesistype='+thesistype+'&thesisname='+encodeURI(thesisname)+'&pagefrom='+pagefrom+'&pagenum='+pagenum;
   window.open(url,'_blank',
"top=40,left=40,toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=no,resizable=yes,width=" +w + ",height=" +h); 
   }
}