function highlight_border(theRow, theRowNum, theAction, theDefaultColor, thePointerColor)
{
    var theCells = null;

    if ((thePointerColor == '') || typeof(theRow.style) == 'undefined') {
        return false;
    }

    if (typeof(document.getElementsByTagName) != 'undefined') {
        theCells = theRow.getElementsByTagName('td');
    }
    else if (typeof(theRow.cells) != 'undefined') {
        theCells = theRow.cells;
    }
    else {
        return false;
    }

    var rowCellsCnt  = theCells.length;
    var domDetect    = null;
    var currentColor = null;
    var newColor     = null;
    if (typeof(window.opera) == 'undefined' && typeof(theCells[0].getAttribute) != 'undefined') {
        currentColor = theCells[0].getAttribute('bordercolor');
        domDetect    = true;
    }
    else {
        currentColor = theCells[0].style.bordercolor;
        domDetect    = false;
    } // end 3

        if (theAction == 'over' && thePointerColor != '') {
            newColor              = thePointerColor;
        }

        if (theAction == 'out' && theDefaultColor != '' ) {
            newColor              = theDefaultColor;
        }

    if (newColor) {
        var c = null;
        if (domDetect) {
            for (c = 0; c < rowCellsCnt; c++) {
                theCells[c].setAttribute('bordercolor', newColor, 0);
            } // end for
        }
        else {
            for (c = 0; c < rowCellsCnt; c++) {
                theCells[c].style.bordercolor = newColor;
            }
        }
    } // end

    return true;
} // end function



function highlight_cell(theCell, theCellNum, theAction, theDefaultColor, thePointerColor, theProperty)
{

    if ((thePointerColor == '') || typeof(theCell.style) == 'undefined') {
        return false;
    }
    
    if (typeof(document.getElementsByTagName) != 'undefined') {
        subItems = theCell.getElementsByTagName('div');
    } // end if


    var subsCount  = subItems.length;


    var domDetect    = null;
    var currentColor = null;
    var newColor     = null;
    if (typeof(window.opera) == 'undefined' && typeof(theCell.getAttribute) != 'undefined') {
        currentColor = theCell.getAttribute(theProperty);
        domDetect    = true;
    }
    else {
        currentColor = theCell.style.theProperty;
        domDetect    = false;
    } // end 3

        if (theAction == 'over' && thePointerColor != '') {
            newColor              = thePointerColor;
        }

        if (theAction == 'out' && theDefaultColor != '' ) {
            newColor              = theDefaultColor;
        }

    if (newColor) {
        var c = null;
        if (domDetect) {
            theCell.setAttribute(theProperty, newColor, 0);
        }
        else {
             theCell.style.theProperty = newColor;
        }
    } // end
    
    if (newColor) {
        var c = null;
        if (domDetect) {
            for (c = 0; c < subsCount; c++) {
                subItems[c].setAttribute(theProperty, newColor, 0);
            } // end for
        }
        else {
            for (c = 0; c < subsCount; c++) {
                subItems[c].style.theProperty = newColor;
            }
        }
    } // end

    return true;
} // end function