// JavaScript Document
//開啟新視窗
function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

//重新調整視窗大小
function MM_WindowsReSize( intWindowsW, intWindowsH ){
  //var intWindowsW = 950;
  //var intWindowsH = 700;
  //依照核心跟瀏覽器判斷要加多少像素
  if ( navigator.appName.indexOf( "Microsoft Internet Explorer" ) >= 0 ){ // IE核心
    if ( navigator.appVersion.indexOf( "Maxthon" ) >= 0 ){ // Maxthon瀏覽器
      intWindowsW = intWindowsW + 15;
      intWindowsH = intWindowsH + 39;
    }else{
      intWindowsW = intWindowsW + 0;
      intWindowsH = intWindowsH + 31;
    }
    
  }else if( navigator.appName.indexOf( "Netscape" ) >= 0 ){ // Netscape核心
    if ( navigator.appVersion.indexOf( "Chrome" ) >= 0 ){ // Chrome
      intWindowsW = intWindowsW + 12;
      intWindowsH = intWindowsH + 58;
      
    }else if ( navigator.appVersion.indexOf( "Maxthon/3" ) >= 0 ){ // Maxthon 3
      intWindowsW = intWindowsW + 0;
      intWindowsH = intWindowsH + 0;
      
    }else if ( navigator.appVersion.indexOf( "5.0" ) >= 0 ){ // FireFox
      intWindowsW = intWindowsW + 7;
      intWindowsH = intWindowsH + 86;
    }
    
  }else if( navigator.appName.indexOf( "Opera" ) >= 0 ){ // Opera核心
    intWindowsW = intWindowsW + 14;
    intWindowsH = intWindowsH + 50;
  }
  
  window.resizeTo(intWindowsW,intWindowsH + 81); //resize 寬、高
  var intWindowsMoveX = ( screen.width - intWindowsW ) / 2;
  window.moveTo( intWindowsMoveX, 0 ); // moveto 絕對位置
  
  //document.write( navigator.appName.indexOf( "Microsoft Internet Explorer" ) );
  //document.write( "<br />" );
  //document.write( navigator.appName );
  //document.write( "<br />" );
  //document.write( navigator.appVersion );
}