I'm using this code:
Code:
function show(which) {
var m, els, el, i = 0;
if (document.getElementById) {
m = document.getElementById('menu');
els = m.getElementsByTagName('table');
while (el = els.item(i)) {
if (which == i)
el.style.display = (el.style.display != 'block') ? 'block' : 'none';
else el.style.display = "none";
i++;
}
}
}
to have a menu toggled, and in the 'menu' element of the page, i have an image named menuimg, and i'm having trouble making the image change source to alternate images, depending on what style the 'table' element has (blocked/none)

please can someone help me