当前位置: 编程技术>WEB前端
jquery 表格排序、实时搜索表格内容(附图)
来源: 互联网 发布时间:2014-08-25
本文导语: 代码如下: First Name Last Name Email Phone Number John Smith john.s (613) 873-2982 Sean MacIsaac seanjmacisaac (613) 871-6191 Tim Zarby zarbytown214@hotmail.com (613) 743-5389 Andrew Nichols andy_money2003 (613) 741-3384 Ally O'Neil allyoneil (613) 642-9831 To make a table ...
代码如下:
First Name
Last Name
Phone Number
John
Smith
john.s
(613) 873-2982
Sean
MacIsaac
seanjmacisaac
(613) 871-6191
Tim
Zarby
zarbytown214@hotmail.com
(613) 743-5389
Andrew
Nichols
(613) 741-3384
Ally
O'Neil
allyoneil
(613) 642-9831
To make a table searchable, add the class 'table-sort-search' to the tag.
Example:
First Name
Last Name
Phone Number
John
Smith
john.s
(613) 873-2982
Sean
MacIsaac
seanjmacisaac
(613) 871-6191
Tim
Zarby
zarbytown214@hotmail.com
(613) 743-5389
Andrew
Nichols
(613) 741-3384
Ally
O'Neil
allyoneil
(613) 642-9831
To make the search text input show the search match count, add the class 'table-sort-show-search-count' to the tag.
Example
First Name
Last Name
Phone Number
John
Smith
john.s
(613) 873-2982
Sean
MacIsaac
seanjmacisaac
(613) 871-6191
Tim
Zarby
zarbytown214@hotmail.com
(613) 743-5389
Andrew
Nichols
(613) 741-3384
Ally
O'Neil
allyoneil
(613) 642-9831