phpGrid has built-in jQuery rating plugin support since version 7.1.5. In set_col_format(), simply use “rating” as the format type. The value must be an integer from 1 to 5.
1 2 3 4
| $dg = new C_DataGrid("SELECT id, Contact_Last, Title, Company, Rating, Email FROM contact", "id", "contact");
$dg->set_col_format('Rating', 'rating'); $dg->set_dimension(800);
$dg -> display(); |
See Live Demo!
Related Posts
Complete Date Format Demo (Updated)The example demonstrates date column formatting using functions set_col_date, set_col_datetime, set_col_property(...formatter"=>"date",...). If you have trouble with…
Data Format DisplayphpGrid comes with several frequently used data formatter through set_col_format() method. Different data format has different…
Conditional Format ** Please note this feature is not available in Lite and Basic versions. Conditional…