function showhidden(name,idx){
	var o = document.getElementsByName(name);
	try{
		for(var i=0;i<o.length;i++){
			if(i == idx){
				o[i].style.display = '';
			}else{
				o[i].style.display = 'none';
			}
		}
	}catch(e){
		;
	}
}

function findPos(o)
{
    this.top  = o.offsetTop;
    this.left = o.offsetLeft;
    while(o = o.offsetParent)
    {
        this.top  += o.offsetTop;
        this.left += o.offsetLeft;
    }
}

function showview(a,b)
{
	var menuObj = document.getElementById(b);
	var titleObj = document.getElementById(a);
	
	var posObj = new findPos(titleObj);
	var menu_left = posObj.left;
	var menu_top = posObj.top + parseInt(titleObj.offsetHeight);

	menuObj.style.display = '';
	
	// 计算显示位置
	if (posObj.left + menuObj.offsetWidth >= document.body.clientWidth && 0)
	{
		menu_left = parseInt(posObj.left) - parseInt(menuObj.offsetWidth) + parseInt(titleObj.offsetWidth);
	}
	
	menuObj.style.left =  menu_left + 'px';
	menuObj.style.top = (menu_top - 1) + 'px';	
}