// Global variables

var LPIP="http://lpis.dpm.org.cn:8087/";
//var LPIP="http://172.17.110.81:8087/";

//var objwin=null;
function openobjwin(objid,objtype)
{
// if (!objwin||objwin.closed)
// {
  var w,h;
  //w=window.screen.availWidth-30;
 // h=window.screen.availHeight-80;
 w=790;
 h=490;
  if (objtype==3 || objtype==9) 
  {w=600;
   h=425;
  	}
 objwin=window.open("/english/phoweb/asp/objdetail.asp?objid=" + objid + "&objtype=" + objtype,objid+'obj',
"top=20,left=0,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=" +w + ",height=" +h); 
// }else{
//  objwin.focus();
// }
//if it open more obj window, it will apear the same obj content.
}

//只为打标而用 
function openthesiswin(thesisid)
{
  var w,h;
  w=window.screen.availWidth-50;
  h=window.screen.availHeight-80;
 window.open(str="/english/phoweb/asp/thesisDetail.asp?thesisid=" + thesisid,thesisid+'thesis',
"top=40,left=40,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=" +w + ",height=" +h); 
}

function openthesiswin2(thesisid,thesistype,thesisname)
{
  var w,h;
  var aspname;
  w=window.screen.availWidth-50;
  h=window.screen.availHeight-80;
  if (thesistype==0) 
  {aspname="/english/phoweb/asp/thesis0.asp?thesisid=";
  window.open(aspname+thesisid+'&thesistype='+thesistype+'&thesisname='+thesisname,thesisid+'thesis2',
"top=40,left=40,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=" +w + ",height=" +h); 
  }
  else if(thesistype==1) {
  w=window.screen.availWidth-80;
  h=window.screen.availHeight-90;
  aspname="/english/phoweb/asp/thesis1.asp?thesisid=";
   window.open(aspname+thesisid+'&thesistype='+thesistype+'&thesisname='+thesisname,thesisid+'thesis2',
"top=40,left=40,toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,resizable=yes,width=" +w + ",height=" +h); 
   }
  else { 
  aspname="/english/phoweb/asp/thesis2.asp?thesisid=";
  window.open(aspname+thesisid+'&thesistype='+thesistype+'&thesisname='+thesisname,thesisid+'thesis2',
"top=40,left=40,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=" +w + ",height=" +h); 
  }
  
 
}

function openthesisloc(thesisid,pagenum,thesisname)
{
  var w,h;
  var aspname;
  w=window.screen.availWidth-80;
  h=window.screen.availHeight-90;
  
 window.open("/english/phoweb/asp/thesischapter.asp?thesisid="+thesisid+'&pagenum='+pagenum+'&thesisname='+thesisname,thesisid+pagenum+'loc',
"top=40,left=40,toolbar=no,location=no,directories=no,status=yes,menubar=no,scrollbars=yes,resizable=yes,width=" +w + ",height=" +h); 
}

function openlemmawin(lemmaid)
{
  var w,h;
  w=window.screen.availWidth-200;
  h=window.screen.availHeight-100;
  lemmawin=window.open("/english/phoweb/asp/lemmadetail.asp?lemmaid=" + lemmaid ,lemmaid+'lemma',
"top=100,left=100,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=no,width=450,height=300"); 
}


function openmidimgwin(imageid,suffix,width,height,havemid,havelp,imgtitle) 
{  
var w,h;
w=width;
h=height
if (width==0 ||width=="") w=window.screen.availWidth-200;
if (height==0 ||height=="") h=window.screen.availHeight-100;
window.open("/english/phoweb/asp/showbigimg.asp?imageid=" +imageid +"&image_suffix=" +suffix+"&havemid=" +havemid+"&havelp=" +havelp+"&imgtitle=" +imgtitle ,imageid+'midimg',
"top=60,left=60,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width="+ w + ",height="+h );
} 


function openlpimgwin(id,havelp,imgtitle) 
{  
window.open("/english/phoweb/asp/showlp.asp?imageid=" + id + "&havelp=" +havelp+"&imgtitle=" +imgtitle,id+'lp',
"top=100,left=100,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=302,height=302");
} 


function openmoreimgwin(objid)
{    window.open("/english/phoweb/asp/moreimg.asp?objid=" + objid ,objid+'moreimg',
"top=92,left=0,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=790,height=450"); 
}

function openmorethesiswin(objid)
{
 window.open("/english/phoweb/asp/morethesis.asp?objid=" + objid ,objid+'morethesis',
"top=92,left=0,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=790,height=450"); 
}

function openmoreconwin(objid)
{
  window.open("/english/phoweb/asp/mingrenjuanzeng.asp?objid=" + objid ,objid+'morecon',
"top=92,left=0,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=790,height=450"); 
}

function MM_openLP(theURL,winName,features) { //v2.0
  var a;
  a=LPIP+theURL;
  window.open(a,winName,features);
}

function openstaticlp(id,havelp,imgtitle) 
{  
window.open("/english/phoweb/asp/showstaticlp.asp?imageid=" + LPIP + "fif=" + id + "&havelp=" +havelp+"&imgtitle=" +imgtitle,'',
"top=100,left=100,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=302,height=302");
} 
function openforwardplatewin(objid,suffix)
{
 window.open("/english/phoweb/asp/objdetail.asp?objid=" + objid + "&objtype=11&suffix=" + suffix,objid+suffix,
"top=92,left=0,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,width=790,height=490"); 
}
