Dear all, Below is my code.Can anybody guide me how can i use pagination on data grid in codeignator??
function viewAllList()
{
$sql = '(SELECT id,songName,albumName,artistName,category FROM tbl_rbt )as abc';
$getInstance = & get_instance();
$getInstance->load->library('rapyd');
$this->rapyd->load('datagrid');
$grid = new DataGrid('', $sql);
$grid->column('Song Name', 'songName', 'align=\'left\'');
$grid->column('Album Name','albumName', 'align=\'left\'');
$grid->column('Artist Name','artistName', 'align=\'left\'');
$grid->column('Category', 'category', 'align=\'left\'');
$linkshow = anchor('admin_controller/editRbt/<#id#>', 'Edit');
$linkshow .= ' ' . anchor('admin_controller/deleteRbt/<#id#>', 'Delete', 'onclick = "return checkDelete();"');
$grid->column('Actions', $linkshow,'align=\'left\' width="100px"');
$grid->build();
return $grid->output;
}
I need urgent help.Pls help
Thanks in advance
Riad