//onMouseOver="chcolor(this, '#FF0000')" onMouseOut="redocolor(this)"
function RGBToHex(ColorString) {
HexDigits = "0123456789abcdef";
if (ColorString.charAt(0) == '#') {
return ColorString;
} else {
ColorString = ColorString.substr(4);
pos = ColorString.indexOf(',');
Result = '#' + HexDigits.substr(Math.floor(ColorString.substr(0, pos) / 16), 1) + HexDigits.substr(ColorString.substr(0, pos) % 16, 1);
ColorString = ColorString.substr(pos + 1);
pos = ColorString.indexOf(',');
Result = Result + HexDigits.substr(Math.floor(ColorString.substr(0, pos) / 16), 1) + HexDigits.substr(ColorString.substr(0, pos) % 16, 1);
ColorString = ColorString.substr(pos + 1);
Result = Result + HexDigits.substr(Math.floor(ColorString.substr(0, pos) / 16), 1) + HexDigits.substr(ColorString.substr(0, pos) % 16, 1);
return Result;
}
}
old_color = '';
current_color = '';
function chcolor(elem, new_col) {
old_color = start_color = RGBToHex(elem.style.color)
current_color = new_col;

bytefx.color(
elem,
"color",
start_color,
new_col,
10
);
}
function redocolor(elem) {
bytefx.color(
elem,
"color",
current_color,
old_color,
5
);
}