[Rails-spinoffs] table sorting/manipulation library?

Felipe Gasper
Wed, 14 Sep 2005 22:12:20 -0000

Hm - I don''t have access to a Safari box.

Any idea what might be the caveat. I know that Safari, before the very
latest version, had issues with its table properties like
sectionRowIndex, rowIndex, cellIndex, rows, cells, etc.

-FG

Quoth Mark McCray on 9/14/2005 10:13 PM...
> Really cool.
> Though on Safari, it doesn''t seem to work for me.
> Mark
>
>
> On Sep 14, 2005, at 10:04 PM, Felipe Gasper wrote:
>
>> Yeah, that''s an old link. A new one, with demo, is:
>>
>> http://fshn-dads.foods.uiuc.edu/demo/supertable-demo.html
>>
>> Comments/suggestions welcome.
>>
>> -FG
>>
>> Quoth Ed C. on 9/14/2005 9:32 PM...
>>
>>> The URL in the footer of Felipe''s email links to
"http://
>>> ccm.uc.edu/sacredmusic/lib/supertable.js" after a couple
clicks ;)
>>> Hope that helps, Ed C.
>>> On 9/14/05, *Andrew Kaspick* <akaspick@gmail.com
>>> <mailto:akaspick@gmail.com>> wrote:
>>>     Do you have a url with a demo for us to see?  I can''t
see why  there
>>>     wouldn''t be any interest for a library like this, so
give us a
>>> taste!
>>>     :)
>>>     On 9/14/05, Felipe Gasper <gasperfm@uc.edu
>>> <mailto:gasperfm@uc.edu>>
>>>     wrote:
>>>      > I have a library I''ve developed that I believe
is the most
>>>     flexible and
>>>      > useful table sorting/striping/row-selecting library
around.
>>>      >
>>>      > Big features:
>>>      > Single and multiple-level sort
>>>      > Arbitrary sort criteria (IP address, date, etc.)
>>>      > Works with table headers that are > 1 row or column
large
>>>      > Stripe tables and/or enable row selecting
>>>      > Row selecting supports drag-select and SHIFT-click
>>>      > No extra HTML; all CSS and Javascript
>>>      > Optionally creates buttons: "Default Sort",
"Select all", etc.
>>>      > Quite fast
>>>      > Pretty good cross-browser support (AFAIK)
>>>      >
>>>      > All the other table-sorting libraries I''ve found
try to
>>> "guess" what
>>>      > they''re sorting. This library makes no attempt
to do so,  instead
>>>      > assuming the designer can tell it how to sort by giving
it  a
>>> function
>>>      > for each sortable column that returns a value to be
sorted.
>>>      >
>>>      > An example:
>>>      >
>>>      > -----------------
>>>      > <table id="myTable" class="sortable
striped rowsSelectable">
>>>      >
string number date </
>>> tr>
>>> >
>>> >
>>>      > ..........
>>> >
>>> >
>>>      >
>>> >
>>>      >
document.getElementById(''myTable'').sorterFuncs = [
>>>      >         String,
>>>      >         Number,
>>>      >         function(str) {
>>>      >                 var dateSplit = str.split(/\D/);
>>>      >
>>>      >                 //assume we''re in MM/DD/YYYY
format
>>>      >                 return (dateSplit[2] * 10000)
>>>      >                    + (dateSplit[0] * 100)
>>>      >                    + (str[1] * 1);
>>>      >         }
>>>      > ];
>>> >
>>>      > ----------------------
>>>      >
>>>      > That''s it. Our table now correctly sorts by
clicking on the
>>> table
>>>     headers.
>>>      > If you want, add "multisort" to the
table''s class, and you
>>> get the
>>>      > equivalent of multiple "ORDER BY" arguments to
an SQL  statement.
>>>      >
>>>      > Is there interest around in a library like this?
>>>      >
>>>      > -Felipe Gasper
>>>      > Cincinnati, OH
>>>      >
>>>      > --
>>>      > Felipe M. L. Gasper, conductor/singer
>>>      > http://felipegasper.com
>>>      >
>>>      > Judge ideas, not people.
>>>      > Love people, not ideas.
>>>      > _______________________________________________
>>>      > Rails-spinoffs mailing list
>>>      > Rails-spinoffs@lists.rubyonrails.org
>>>     <mailto:Rails-spinoffs@lists.rubyonrails.org>
>>>      >
http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
>>>
<http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs>
>>>      >
>>>     _______________________________________________
>>>     Rails-spinoffs mailing list
>>>     Rails-spinoffs@lists.rubyonrails.org
>>>     <mailto:Rails-spinoffs@lists.rubyonrails.org>
>>>     http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
>>>
---------------------------------------------------------------------
>>> ---
>>> _______________________________________________
>>> Rails-spinoffs mailing list
>>> Rails-spinoffs@lists.rubyonrails.org
>>> http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
>>>
>>
>> --
>> Felipe M. L. Gasper, conductor/singer
>> http://felipegasper.com
>>
>> Judge ideas, not people.
>> Love people, not ideas.
>> _______________________________________________
>> Rails-spinoffs mailing list
>> Rails-spinoffs@lists.rubyonrails.org
>> http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs
>>
>>
>
> _______________________________________________
> Rails-spinoffs mailing list
> Rails-spinoffs@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails-spinoffs

--
Felipe M. L. Gasper, conductor/singer
http://felipegasper.com

Judge ideas, not people.
Love people, not ideas.