My problem arises on the onmouseout event. Instead of calling an unnamed function, I would rather call a named function outside of 'colour'. However, I'm having much trouble passing arguments and don't know how to do this - or whether I can at all.
I would like the code to look something like this:
rows[i].onmouseout = changeBack(defaultColor);
But I know that this would initiate 'changeBack' right then and there, and it wouldn't have access to defaultColor.