Day: February 12, 2010


jQuery to check the row count of a table

To get the row count of the table, in jQuery, all you need to do is use any of the following approaches: $("#mytable tr").length $("#mytable tr").size() //But the size method calls the length property internally One thing to be noted here is that the indexing is 1-based and not 0-based. For ex.: <html> <head> <script ...