function chtopmenu (id) {
  var id2=parseInt(id)+1;
  var van=document.getElementById('potty_'+id).src.indexOf('images/top_menu_bg_light2.gif');
  if (van!=-1)
  {
    document.getElementById('potty_'+id).src="images/top_menu_bg.gif";
    document.getElementById('potty_'+id2).src="images/top_menu_bg.gif";
  }
  else
  {
    document.getElementById('potty_'+id).src="images/top_menu_bg_light2.gif";
    document.getElementById('potty_'+id2).src="images/top_menu_bg_light2.gif";
  }
}

function openclose(id,op) {
	var obj=document.getElementById(id);
	if (obj.style.display=='block')
	{
		if (op!=-1)
		{
			obj.style.display='none';
			document.getElementById('switcher').src='images/plus.gif';
		}
	}
	else
	{
		obj.style.display='block';
		document.getElementById('switcher').src='images/minus.gif';
	}
}

function chLeiras() {
	var wp=document.getElementById('wp').value;
	var task=document.getElementById('task').value;
	
	var leiras_wp=document.getElementById('leiras_'+wp).value;
	var leiras_task=document.getElementById('leiras_'+task).value;

	if (leiras_wp.length>0) document.getElementById('wp_leiras').innerHTML='<p>'+leiras_wp+'</p>';
	if (leiras_task.length>0) document.getElementById('task_leiras').innerHTML='<p>'+leiras_task+'</p>';
}






















