johnpolacek/stacktable.js — pull request #13 by francescomalatesta (2014-10-29 17:52:34+00:00)
Title: Update stacktable.js

Hi johnpolacek! First of all, thank you for stacktable.

I made some edits as I used them in a project. Nothing complex, however.

I added support for headIndex: now you can choose what cell you want to use as header for a row.

For example, if you want to use the second cell as header, all you have to do is:

$(selector).stacktable({headIndex:1});

The default value is 0.

I used two different variables to move the header up from every position: headMarkup and bodyMarkup. After the reading process everything goes into markup as usual.

Also, I've done some variable name changes (the two "index" became "rowIndex" and "cellIndex", in order to avoid ambiguities).