You, Mr. Steve Davis, a newb to javascript? ;-)
Glad you came to be part of the jQuery group. Many of us started going that
direction after I got back from a Lasso conference last year.
One of those, "I could have had a V8" moments. I just need to add the tbody
tags to my table. I can get lazy
Hey,
The following code will let you build your row, then insert it after
the first (assumed to be header) row.
// Build your row here:
var row = "blah";
$("#yourTable tr:first").after(row);
You might want to change your table to be of the format:
...
.
T
i would make the first row a "th" then have it do a $("th").after(add
your TR here);
but im a total newbie to javascript and jquery
On Feb 15, 2:48 pm, Shelane <[EMAIL PROTECTED]> wrote:
> I would like to add a row to a table. The first row is a header. So
> I want to add it just under the hea
$("tr#header").after("new content");
if you use semantically correct table structure, you could just
prepend your new row to the top of the tbody, where it'd obviously be
after the header...
Header
Content
$("tbody").prepend("new content");
i'd assume these both should work...
--adam
4 matches
Mail list logo