Monday, May 20, 2024
 Popular · Latest · Hot · Upcoming
150
rated 0 times [  156] [ 6]  / answers: 1 / hits: 181751  / 15 Years ago, mon, april 6, 2009, 12:00:00

I thought this might be a fast way to remove the contents of a very large table (3000 rows):



$jq(tbody, myTable).remove();


But it's taking around five seconds to complete in firefox. Am I doing something dumb (aside from trying to load 3000 rows in to a browser)? Is there faster way to do it?


More From » jquery

 Answers
12
$(#your-table-id).empty();


That's as fast as you get.


[#99739] Wednesday, April 1, 2009, 15 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
jelani

Total Points: 473
Total Questions: 99
Total Answers: 99

Location: Cape Verde
Member since Fri, Nov 27, 2020
4 Years ago
;