/*-- onload execution --*/
  if (dl.is.ie6){  dl.load.push("document.execCommand('BackgroundImageCache', false, true)"); }
/*-- site functions --*/
/* email rewriting */
function eml(cls,a,b,c){document.write('<a href="mailto:'+a+'@'+b+'.'+c+'" class="'+cls+'" onfocus="this.blur()">'+a+'@'+b+'.'+c+'</a>');}
/* library functions */
add=function(tag,cls,par)
{	//var el=(tag=='IFRAME'&&!ns6)? document.createElement('<IFRAME FRAMEBORDER=0 allowTransparency="true"></IFRAME>') : document.createElement(tag);
	var el=document.createElement(tag);
	if(cls)	el.id=el.className=cls;
	if(par) par.appendChild(el)
return el;
}
/* open/close element */
function show(id)
{	var body=document.getElementsByTagName('body').item(0);
	var html=dl.d.getElementsByTagName('html').item(0);
	var selArr=document.getElementsByTagName('select');
	dl.el(id).on();
	dl.el(id).style.marginLeft=-parseInt(dl.el(id).offsetWidth/2)+parseInt(html.scrollLeft)+'px';
	dl.el(id).style.marginTop=-parseInt(dl.el(id).offsetHeight/2)+parseInt(html.scrollTop)+'px';
	if(selArr)
		for(var i=selArr.length-1;i>=0;i--)	selArr[i].style.visibility="hidden";
	if(!dl.is.el('over')) add('DIV','over',body);
	dl.el('over').on();
	dl.el('over').onclick=function(){hide(id)};
	dl.el('over').style.height=html.scrollHeight+'px';
}
function hide(id)
{	if (!dl.is.el(id)) return;
	dl.el(id).off();
	if(dl.is.el('over')) dl.el('over').off();
	var selArr=document.getElementsByTagName('select');
	if(selArr)
		for(var i=selArr.length-1;i>=0;i--)	selArr[i].style.visibility="visible";
}
/* third menu functionality */
info={curr:'',active:'',scrEl:{}}
info.open=function(id,activeId){
	if (id){
		if(this.curr&&this.curr!=id){
			dl.el(this.curr).off();
		} 
		this.curr=id;
		dl.el(this.curr).on();
		this.scrollV(this.curr);
	}
	if (activeId){
		if(this.active&&this.active!=activeId){
		dl.el(this.active).className='';
		} 
		this.active=activeId;
		dl.el(this.active).className='active';
	}
}
info.scrollV=function(id){
	var scrArr = dl.el(id).getElementsByTagName('div');
	for(var i=scrArr.length;i--;){
		if(scrArr[i].className == 'scroll') {
			this.scrEl = scrArr[i];
			break;
		}
	}
	el = this.scrEl;
	if (el.scrollHeight>el.offsetHeight){
		var imgT = dl.dom.el('img',el.parentNode,{'src':'img/scrollT.gif','class':'scrollT'});
		imgT.style.top = el.offsetTop+'px';
		imgT.onclick=function(){ info.scrEl.scrollTop-=20; }
		imgT.onmousedown=function() {	t=setInterval("info.scrEl.scrollTop-=10",30); }
		imgT.onmouseup=function() { clearInterval(t) }
		var imgB = dl.dom.el('img',el.parentNode,{'src':'img/scrollB.gif','class':'scrollB'});
		imgB.onclick=function(){ info.scrEl.scrollTop+=20; }
		imgB.onmousedown=function() {	t=setInterval("info.scrEl.scrollTop+=10",30); }
		imgB.onmouseup=function() { clearInterval(t) }
	}
}
/* menu over functionality */
menu={toff:[]}
menu.open=function(id,e)
{	if(dl.is.el(id)){
		if(this.toff[id]) clearTimeout(this.toff[id]);
		dl.el(id).onmouseover=function(){this.ob=(this.ob)?this.ob:new fade();menu.open(this.id)};
		dl.el(id).onmouseout=function(){menu.close(this.id)};
		dl.el(id).on();
		dl.el(id).ob=(dl.el(id).ob)?dl.el(id).ob:new fade(id);
		dl.el(id).ob.go(1);
	}
}
menu.close=function(id,e)
{	if(dl.is.el(id)){
		dl.el(id).ob.onend=function(){ if(this.dir<0) dl.el(id).off() };//invisible subMenu
		this.toff[id]=setTimeout("dl.el('"+id+"').ob.go(-1);",50);
	}
}
//dl.load.push("dl.make('DIV');");

