Download the PHP package murzid/codeigniter-datatables without Composer
On this page you can find all versions of the php package murzid/codeigniter-datatables. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download murzid/codeigniter-datatables
More information about murzid/codeigniter-datatables
Files in murzid/codeigniter-datatables
Package codeigniter-datatables
Short Description DataTables server-side for CodeIgniter
License MIT
Informations about the package codeigniter-datatables
CodeIgniter DataTables
DataTables server-side for CodeIgniter, supported for both CodeIgniter 3 and CodeIgniter 4.
Note: This library only handle the server-side part, you still needs to configure the client side like jQuery, DataTables library and including the styles. Don't worry, we already give the examples below.
Requirements
If you are using CodeIgniter, let's go! You don't needs any extra requirements.
Installation
You just need to use composer and everything is done.
Usage
Here is the basic example to use this library, you are freely make any changes for the client side, like defining searchable column, orderable column, etc...
CodeIgniter 3 Example
CodeIgniter 4 Example
The above examples will give you for ajax data source (arrays), so you need to make sure the table header you makes for the client side is match with the ajax response. We will talk about the objects data source below.
Client Side Examples
You must include the jQuery and DataTables library.
Objects Data Source
As was mentioned above, the default data source we get is an arrays. It is easy also to get the objects data source.
To get objects response, you just need to call asObject()
method.
And then you can configure the client side with columns option to fit your data.
Some Others Settings
Some basic functionalities already available, here is the full settings you can doing to this library.