This is sorta my first little javascript, and I'm not having any success
getting it to work:
=====================
function switchdiv()
{
ShowHide('display');
ShowHide('edit');
}
function ShowHide(divId)
{
var id = document.getElementById(divId);
if (id.style.display == "none")
{
eval("id.style.display = 'block';");
}
else
{
eval("id.style.display = 'none';");
}
}
====================
When I call switchdiv, the script succeeds at hiding 'display' but
doesn't seem to show 'edit'. However, if I run switchdiv like this:
===================
function switchdiv()
{
ShowHide('edit');
}
==================
....it shows 'edit' just fine. I must be missing something obvious!
Thanks for any help!
--Brent