//<![CDATA[
 
/*
        The following callback function renumbers the first cell within each table row for the table "theTable"
*/
function sortCompleteCallbacktheTable() {
        // Grab the TR's
        var trs = document.getElementById("theTable").getElementsByTagName('tbody')[0].getElementsByTagName('tr');
        // Declare a variable to hold a reference to the TD node
        var cell;
        // Loop through the TR node collection
        for(var i = 0, tr; tr = trs[i]; i++) {
                // Grab the first TD within this TR
                cell = tr.getElementsByTagName("td")[0];
                // Delete it's contents
                while(cell.firstChild) cell.removeChild(cell.firstChild);
                // Append a text node
                cell.appendChild(document.createTextNode(i + 1));
        }
}
 
//]]>