function toggle() {

   var src = window.event.srcElement;

if ((src.tagName=="SPAN") && (src.id.substr(0,8)=="_comment")) {

	if (src.id.substr(0,11)=="_commentref") {
    		var e=document.all("_comment" + src.id.substr(11)); 

	} else {
    		var e=src; //self
	}



	  if (e.style.display == "none") {
     		e.style.display = "";
	  } else {
	     e.style.display = "none";
	  }

}

}

function initIt()
// для всех тагов div
  { tempColl = document.all.tags("span");
 
    for (i=0; i<tempColl.length; i++)
     { if (tempColl(i).className == "rashi") tempColl(i).style.display = "none";
     }
  }

function showAll()
// для всех тагов div
  { tempColl = document.all.tags("span");
 
    for (i=0; i<tempColl.length; i++)
     { if (tempColl(i).className == "rashi") tempColl(i).style.display = "";
     }

document.all("tglComments").innerHTML="Убрать все комментарии";

  }


function hideAll()
// для всех тагов div
  { tempColl = document.all.tags("span");
 
    for (i=0; i<tempColl.length; i++)
     { if (tempColl(i).className == "rashi") tempColl(i).style.display = "none";
     }

document.all("tglComments").innerHTML="Показать все комментарии";


  }

function tglAll() {

if (document.all("tglComments").innerHTML=="Показать все комментарии") {
	showAll() ;
} else {

	if (document.all("tglComments").innerHTML=="Убрать все комментарии") {
	hideAll();

	}
}

}



 function underline() {
        var src = window.event.srcElement; 
        if ((src.tagName=="SPAN") && (src.className=="rashi_ref" || src.className=="comment_handle")) {
          
        src.style.textDecoration="underline"; 
       }
       }

        function nounderline() {
        var src = window.event.srcElement; 
        if ((src.tagName=="SPAN") && (src.className=="rashi_ref" || src.className=="comment_handle")) {
          
        src.style.textDecoration=""; 
       }
       }

