<!--
  bname = navigator.appName;
  bver  = parseInt(navigator.appVersion);
  var loopc = 0;
  var reala = 0;

function playAudio(file) {
  loopc = 0;
  if (reala == 0) {
    if (bname== "Netscape" && bver >= 4)
      {
      document.layers['sound'].document.open('text/html');
      document.layers['sound'].document.write('<EMBED NAME=javaplayer TYPE="audio/x-pn-realaudio-plugin" SRC ="' + file + '" WIDTH=180 HEIGHT=80 AUTOSTART=-1></EMBED>');
      document.layers['sound'].document.close();
      while (loopc == 0) { loopc = document.layers['sound'].document.javaplayer.CanPlay(); }
      document.layers['sound'].document.javaplayer.DoPlay();
      }
    if (bname == "Microsoft Internet Explorer" && bver >= 4)
      {
      var xs = document.location;
      var ys = new String(xs);
      var zs = ys.indexOf('cgi');
      // alert(ys.substring(0,zs)+file.substring(3));
      rfile = ys.substring(0,zs) + file.substring(3);
      Player.URL = rfile;
      // sound.innerHTML = '<OBJECT ID="MPlyr" CLASSID="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95"><PARAM NAME="FileName" VALUE="' + file + '"><PARAM NAME="AutoStart" VALUE="true"></OBJECT>';
      }
  }
  if (reala == 1) {
    if (bname== "Netscape" && bver >= 4)
      {
      document.layers['sound'].document.open('text/html');
      document.layers['sound'].document.write('<EMBED TYPE="application/x-mplayer2" SRC="' + file + '" NAME="MediaPlayer" WIDTH=320 HEIGHT=240 AUTOSTART=-1></EMBED>');
      document.layers['sound'].document.close();
      }
    if (bname == "Microsoft Internet Explorer" && bver >= 4)
      {
      sound.innerHTML = '<EMBED NAME=javaplayer TYPE="audio/x-pn-realaudio-plugin" SRC ="' + file + '" WIDTH=180 HEIGHT=80 AUTOSTART=-1></EMBED>';
      }
  }
  if (reala == 2) {
    openaw(file);
  }
}

function MM_callJS(jsStr) { //v2.0
  return eval(jsStr)
}

function audio_switch() {
  if (reala == 0) {
    reala = 1;
  } else if (reala == 1) {
    reala = 2;
  } else if (reala == 2) {
    reala = 0;
  }
  SetCookie("AudioSet", reala, exp);
  var realass = reala + 1;
  alert("系統將嘗試第 " + realass + " 種撥放語音方式");
}

function openaw (file) {

  width  = 350;
  height = 60;
  IENSX  = window.screen.availWidth - 380;
  IENSY  = 25;

  win77 = window.open("","myWin77",'width=' + width + ',height=' + height + ',scrollbars=no');
  if (document.layers || document.all)
  { 
    win77.moveTo(IENSX,IENSY);
  }
  win77.focus();
  win77.location.href= 'http://www.1390.com.tw/cgi-bin/playaudio?' + file;
  win77.opener=self;
}

function DicLookup(sword) {

  width  = 418;
  height = 460;
  IENSX  = window.screen.availWidth - 450;
  IENSY  = 25;

  win117 = window.open("","myWin77",'width=' + width + ',height=' + height + ',scrollbars=yes');
  if (document.layers || document.all)
     { 
       win117.moveTo(IENSX,IENSY);
     }
  win117.focus();
  win117.location.href= 'http://www.e390.com/cgi-bin/e390dic?UID=1390&MYINPUT=' + sword + '&CMP=3&SUBMIT=GO';
  win117.opener=self;
}

var expDays = 365;
var exp = new Date();
var uname = ''; 
exp.setTime(exp.getTime() + (expDays*24*60*60*1000));

function getplug() {
	window.location.href = '../free/getplug.htm';
}

function getCookieVal (offset) {  
	var endstr = document.cookie.indexOf (";", offset);  
	if (endstr == -1)    
		endstr = document.cookie.length;  
		return unescape(document.cookie.substring(offset, endstr));
}

function GetCookie (name) {  
	var arg = name + "=";  
	var alen = arg.length;  
	var clen = document.cookie.length;  
	var i = 0;  
	while (i < clen) {    
	var j = i + alen;    
	if (document.cookie.substring(i, j) == arg)      
		return getCookieVal (j);    
		i = document.cookie.indexOf(" ", i) + 1;    
		if (i == 0) break;   
	}  
	return null;
}

function SetCookie (name, value) {  
	var argv = SetCookie.arguments;  
	var argc = SetCookie.arguments.length;  
	var expires = (argc > 2) ? argv[2] : null;  
	var path = (argc > 3) ? argv[3] : null;  
	var domain = (argc > 4) ? argv[4] : null;  
	var secure = (argc > 5) ? argv[5] : false;  
	document.cookie = name + "=" + escape (value) + 
	((expires == null) ? "" : ("; expires=" + expires.toGMTString())) + 
	((path == null) ? "" : ("; path=" + path)) +  
	((domain == null) ? "" : ("; domain=" + domain)) +    
	((secure == true) ? "; secure" : "");
}

reala = GetCookie ("AudioSet");
if (reala > 2) { reala = 0; }
if (reala < 0) { reala = 0; }
if (reala == null) { reala = 0; } 
//-->