

function eid(n){return document.getElementById(n);}

if ('undefined'==typeof String.prototype.trim){String.prototype.trim=function() {return this.replace(/^\s+/, '').replace(/\s+$/, '');}}

function viewfblock(s,c){for(i=0;i<33;i++){bobj=document.getElementById('b'+i);if(bobj)bobj.style.background=c;curobj=document.getElementById('alf'+i);	if(curobj)curobj.style.display='none';}bobj2=document.getElementById('b'+s);curobj2=document.getElementById('alf'+s);bobj2.style.background='#fff';curobj2.style.display='block';}

function ÑhangeDisplayStyle(id, t){o=eid(id);if(o&&t=='block'){o.style.display='block';o.style.visibility='visible';}else if(o&&t=='none'){o.style.display='none';o.style.visibility='hidden';}else if(o){if(o.style.display=='block'||o.style.visibility=='visible') {o.style.display='none';o.style.visibility='hidden';}else if(o.style.display == 'none'||o.style.visibility=='hidden'){o.style.display='block';o.style.visibility='visible';}}}

xmlDoc=new Array();
function w2load(w2page,id) {if(typeof window.ActiveXObject!='undefined'){xmlDoc[id] = new ActiveXObject("Microsoft.XMLHTTP");xmlDoc[id].open("GET",w2page,true);   xmlDoc[id].send(null);xmlDoc[id].onreadystatechange=function(){if(xmlDoc[id].readyState!=4)return;document.getElementById(id).innerHTML=xmlDoc[id].responseText;}}else{xmlDoc[id]=new XMLHttpRequest();xmlDoc[id].open("GET",w2page,true);xmlDoc[id].send(null);xmlDoc[id].onload=function(){if(xmlDoc[id].readyState!=4)return;document.getElementById(id).innerHTML=xmlDoc[id].responseText;}}}

function addBookmark(title,url){if(window.sidebar){window.sidebar.addPanel(title, url,"");}else if(document.all){window.external.AddFavorite( url, title);}else if(window.opera&&window.print){return true;}}



fds=ÑhangeDisplayStyle;

/*function upbutton() {o = eid('but');if(o.className=='a')o.className='m'; else o.className='a';}*/


function show_shadow_form() {
	$("#bg_form").show();
	$("<div class='bg_body_form'></div>").appendTo("#body");
	$("#body").css("overflow", "hidden");
	$("#body").css("padding-right", "20px");
}

function hide_shadow_form() {
	$(".bg_body_form").attr("class", "");
	$('#bg_form').hide();
	$("#body").css("padding-right", "0px");
	$("#body").css("overflow", "auto");
}