// shows and hide by table id works for td tags as well
function show(tableid)
{
document.getElementById(tableid).style.display = 'block'; 
}
function hide(tableid)
{
document.getElementById(tableid).style.display = 'none'; 
}

// shows and hide by div id
function showdiv(divid)
{
document.getElementById(divid).style.visibility = 'visible'; 
}
function hidediv(divid)
{
document.getElementById(divid).style.visibility = 'hidden'; 
}


// shows and hide by check box or radio button
function showhide(box,id)  
{ 
 var elm = document.getElementById(id) 
 elm.style.display = box.checked? "":"none" 
}

// shows and hide by check box or radio button
function hideshow(box,id)  
{ 
 var elm = document.getElementById(id) 
 elm.style.display = box.checked? "none":"" 
}

// shows and hide by drop down
function display(obj,id1,id2,id3) 
{
ownershipvalue = obj.options[obj.selectedIndex].value;
document.getElementById(id1).style.display = 'none';
// moves focus id3
eval('document.theForm.'  + id3 + '.focus();');
if ( ownershipvalue.match(id1) ) {
document.getElementById(id1).style.display = 'block';
// moves focus id2
eval('document.theForm.'  + id2 + '.focus();');
}
}

// hide by class
function hideAllByClass(theClass){
 var allTags = document.getElementsByTagName('*');
 for(i=0; i<allTags.length; i++){
  if(allTags[i].className == theClass) allTags[i].style.display = 'none';
 }
}

