jquery and grabbing td title to tack on new td?
<p>I am trying to get the titles from my td:</p>

<pre><code>    function titleObject(table) {
        var titleArray=[];

        $('tr',table).each(function(i){
                var data={};
                $('td',this).each(function(j){
                        data[j]=$(this).attr('title');
                })
                titleArray.push(data);
        });
        return titleArray;
}
</code></pre>

<p>I am not sure this will work.  The next thing is I want to tack the title on to a td:</p>

<pre><code>    function objectToTable(objectArray,table){
        var body=$('tbody',table);
        var color = colorStyleObject(table);
        var title = titleObject(table);

        body.children().remove();

        if(options.zebra){
                for(var i=0;i&lt;objectArray.length;i++){
                        (i%2)?(tr=$('&lt;tr class="'+options.zebraClass+'"&gt;&lt;/tr&gt;')):(tr=$('&lt;tr&gt;&lt;/tr&gt;'));
                        for(var j in objectArray[i]){
                                tr.append($('&lt;td class="ui-widget-content"&gt;&lt;/td&gt;').html(objectArray[i][j]));
                        }
                        body.append(tr);
                }
        } else {
                for(var i=0;i&lt;objectArray.length;i++){
                        tr=$('&lt;tr&gt;&lt;/tr&gt;');
                        for(var j in objectArray[i]){
                                tr.append($('&lt;td class="ui-widget-content"&gt;&lt;/td&gt;').attr(title[i][j]).css('background-color',color[i][j]).html(objectArray[i][j]));
                        }
                        //$('.ui-widget-content').css('background-color','green');
                        body.append(tr);
                }
        }
    }
</code></pre>

<p>This does not seem to be working.  The page just churns forever.  Am I getting the title correctly?  Am I not tacking it on to the new td line correctly?</p>
