html table - What's the closest jQuery approximation to YUI's DataTable? -
My two top priorities are progressive enhancements and inline editing. I have progressive increments () and inline editing (), but neither . Support for the jQuery UI theme would be nice, but there is a low priority.
Update: Here's an example of what I'm thinking about how the solution looks:
& lt; Table summary = "Full table of table table data" & gt; & Lt; Captions & gt; Increasing my table progressively & lt; / Caption & gt; & Lt; Thead & gt; & Lt; TR & gt; & Lt; Th id = "colA" & gt; Column A & lt; / Th & gt; & Lt; Th id = "colb" & gt; Column B & lt; / Th & gt; & Lt; / TR & gt; & Lt; / Thead & gt; & Lt; Tbody & gt; & Lt; TR & gt; & Lt; Td header = "cola" & gt; Foo & lt; / Td> & Lt; Td header = "colleb" & gt; Bar & lt; / Td> & Lt; / TR & gt; & Lt; TR & gt; & Lt; Td header = "cola" & gt; Bergele & lt; / Td> & Lt; Td header = "colab" & gt; Barjal & lt; / Td> & Lt; / TR & gt; & Lt; / Tbody & gt; & Lt; / Table & gt; ... enter jquery datatable stuff here ... & lt; Script type = "text / javascript" & gt; ProgressivelyEnhanceMyTable (); & Lt; / Script & gt;
I think that would be a great fit.
UPDATE:
You can use the code to convert your table into a javascript object
var $ table = $ ( 'Table'); // Select your table var data = []; // Start the data array $ ('tr', $ table). Create an object to attach the work (i, item) {// loop obj = {} // to the data array through the table obj.name = $ ('Td: eq (0)', $ (this) Text () .tim (); obj.desc = $ ('td: eq (1)', $ (this)). Text () .trim (); Add the object to the data + = obj; // array });
and after that it is for
as
Comments
Post a Comment