var ajax_debug_mode=false;var ajax_request_type="GET";function ajax_debug(text){if(ajax_debug_mode){alert("RSD: "+text);}}function ajax_init_object(){ajax_debug("ajax_init_object() called..");var A;try{A=new ActiveXObject("Msxml2.XMLHTTP");}catch(e){try{A=new ActiveXObject("Microsoft.XMLHTTP");}catch(oc){A=null;}}if(!A&&typeof XMLHttpRequest!="undefined"){A=new XMLHttpRequest();}if(!A){ajax_debug("Could not create connection object.");}return A;}function ajax_do_call(uri,func_name,args){var i,x,n;var post_data;if(ajax_request_type=="GET"){if(uri.indexOf("?")==-1){uri=uri+"?rs="+escape(func_name);}else{uri=uri+"&rs="+escape(func_name);}for(i=0;i<args.length-1;i++){uri=uri+"&rsargs[]="+escape(args[i]);}uri=uri+"&rsrnd="+new Date().getTime();post_data=null;}else{post_data="rs="+escape(func_name);for(i=0;i<args.length-1;i++){post_data=post_data+"&rsargs[]="+escape(args[i]);}}x=ajax_init_object();x.open(ajax_request_type,uri,true);if(ajax_request_type=="POST"){x.setRequestHeader("Method","POST "+uri+" HTTP/1.1");x.setRequestHeader("Content-Type","application/x-www-form-urlencoded");}x.onreadystatechange=function(){if(x.readyState!=4){return;}ajax_debug("received "+x.responseText);var status;var data;status=x.responseText.charAt(0);data=x.responseText.substring(2);if(status=="-"){alert("Error: "+data);}else{args[args.length-1](data);}};x.send(post_data);ajax_debug(func_name+" uri = "+uri+"/post = "+post_data);ajax_debug(func_name+" waiting..");delete x;}function explode(inputstring,separators,includeEmpties){inputstring=new String(inputstring);separators=new String(separators);if(separators=="undefined"){separators="|";}var fixedExplode=new Array(1);var currentElement="";count=0;for(x=0;x<inputstring.length;x++){str=inputstring.charAt(x);if(separators.indexOf(str)!=-1){if(((includeEmpties<=0)||(includeEmpties==false))&&(currentElement=="")){}else{fixedExplode[count]=currentElement;count++;currentElement="";}}else{currentElement+=str;}}if((!(includeEmpties<=0)&&(includeEmpties!=false))||(currentElement!=="")){fixedExplode[count]=currentElement;}return fixedExplode;}function explodeStr(str){var str_r=new Array();var separators="|";var includeEmpties=1;str_r=explode(str,separators,includeEmpties);return str_r;}function setMsg(dom_name,msg_new,type,msg_old){if(type==1){document.getElementById(dom_name).innerHTML="<span style=\"color:green\">"+msg_new+"</span>";setTimeout("setMsg('"+dom_name+"', '"+msg_old+"', 2, '')",1500);}else if(type==2){document.getElementById(dom_name).innerHTML="<span style=\"color:green\">"+msg_new+"</span>";}}function changeDomShow(id){var dom=document.getElementById(id);var tmp=dom.style.display;if(tmp=="none"){dom.style.display='block';}else{dom.style.display='none';}}function showDom(id){document.getElementById(id).style.display='block';}function closeDom(id){document.getElementById(id).style.display='none';}function setCursorPos(id){var dom=document.getElementById(id);if(dom!==null){var txtRange=dom.createTextRange();txtRange.moveStart("character",dom.value.length);txtRange.moveEnd("character",0);txtRange.select();}else{window.focus();}}function submitonce(theform){if(document.all||document.getElementById){for(var i=0;i<theform.length;i++){var tempobj=theform.elements[i];if(tempobj.type.toLowerCase()=="submit"||tempobj.type.toLowerCase()=="reset"){tempobj.disabled=true;}}}}

//--初始化变量--
var rT=true;//允许图像过渡
var bT=true;//允许图像淡入淡出
var tw=150;//提示框宽度

var ns6 = document.getElementById && !document.all;
var ie4 = document.all;
var toolTipSTYLE="";
function initToolTips(){
    if(ns6) toolTipSTYLE = document.getElementById("toolTipLayer").style;
    else if(ie4) toolTipSTYLE = document.all.toolTipLayer.style;
}
function closeToolTip(){
	initToolTips();
    if(ns6) {
    	toolTipSTYLE.display = "none";
	    toolTipSTYLE.left = "0";
	    toolTipSTYLE.top = "0";
    }else if(ie4){
		if (bT) document.all("trans_table").filters[2].Apply();
		document.all("trans_table").filters[0].opacity=0;
		if (bT) document.all("trans_table").filters[2].Play();
		if (bT){
			if (document.all("trans_table").filters[2].status==1 || document.all("trans_table").filters[2].status==0){  
				toolTipSTYLE.display = "none";
			    toolTipSTYLE.left = "0";
			    toolTipSTYLE.top = "0";
			}
		}
		if (!rT && !bT){
			toolTipSTYLE.display = "none";
		    toolTipSTYLE.left = "0";
		    toolTipSTYLE.top = "0";
		}
    }
}
function toolTip(msg, fg, bg){
	initToolTips();
    if(!fg) fg = "#777777";
    if(!bg) bg = "#eeeeee";
    var content =
    '<table id="trans_table" name="trans_table" border="0" cellspacing="0" cellpadding="1" bgcolor="' + fg + '" style="filter:alpha(opacity=100,enabled=1) revealTrans(duration=.2,transition=1) blendtrans(duration=.2);"><td>' +
    '<table border="0" cellspacing="0" cellpadding="3" bgcolor="' + bg + 
    '"><td width=' + tw + '><font face="Arial" color="' + fg +
    '" size="-1">' + msg +
    '</font></td></table></td></table>';
    if(ns6){
      document.getElementById("toolTipLayer").innerHTML = content;
      toolTipSTYLE.display='block'
    }
    if(ie4){
      document.all("toolTipLayer").innerHTML=content;
      toolTipSTYLE.display='block';
      //--图象过渡，淡入处理--
      var cssopaction=document.all("trans_table").filters[0].opacity;
      document.all("trans_table").filters[0].opacity=0;
      if (rT) document.all("trans_table").filters[1].Apply();
      if (bT) document.all("trans_table").filters[2].Apply();
      document.all("trans_table").filters[0].opacity=cssopaction;
      if (rT) document.all("trans_table").filters[1].Play();
      if (bT) document.all("trans_table").filters[2].Play();
    }
}
function clickDiv(str, t){
	toolTip(str, '#FFFF00', 'orange');
	
	if(t >= 1000){
		setTimeout('closeToolTip()' , t);
	}
}
function setXY(evt){
	initToolTips();
    toolTipSTYLE.left = evt.clientX + "px";
    var bdy = (document.documentElement && document.documentElement.clientWidth)?document.documentElement:document.body;
    toolTipSTYLE.top = 20 + bdy.scrollTop + evt.clientY + "px";
}
document.write('<div id="toolTipLayer" name="toolTipLayer" style="position:absolute;display:none;left:0px;top:0px;"></div>');

function closeDiv(){
	document.getElementById('downmsg_emessage').style.display='none';
}
function showHideDiv(){
	var ct = document.getElementById('donwmsg_content');
	var btn = document.getElementById('msg_hidden_btn');
	if(ct.style.display!="none"){
	  ct.style.display = "none"
	  btn.className="msg-hidden-btn-2";
	}else{
	  ct.style.display="block";
	  btn.className="msg-hidden-btn-1";
	}
}