Skip to content

Pure javascript plugin with non intrusive data in <table> in order to filter and sort

License

Notifications You must be signed in to change notification settings

general03/smartable

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Purpose

Pure javascript plugin with non intrusive data in <table> in order to filter and sort

Requirements

None !

Features

  • Add filter <input> in header
  • Add sort <img> in header
  • No inject data in <table> to work, only the id table
  • No jQuery requirement

Installation

<script type="text/javascript" src="smartable.js"></script>

Usage

var sortFilterTable = new smartab({
  tabId : '#table',
  linkUpSort : 'up-sort.png', //default
  linkDownSort : 'down-sort.png', //default
  linkNoSort : 'img/sort.png', //default
  widthFilter : 100, //default
  unsortCols : [1],
  unfilterCols : [1]
});
sortFilterTable.addHeader();

Options

  • tabId : table identifier
  • linkUpSort : up sort image
  • linkDownSort : down sort image
  • linkNoSort : general sort image
  • widthFilter : width of <input> filter in px
  • unsortCols : list of column number don't sortable
  • unfilterCols : list of column number don't filterable

Browser support

Chrome Firefox IE Opera Safari
? Latest ✔ ? ? ?

About

Pure javascript plugin with non intrusive data in <table> in order to filter and sort

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published