Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
tree: a90ba67973
Fetching contributors…

Cannot retrieve contributors at this time

31 lines (20 sloc) 0.851 kb

Data providers

Data provider abstracts getting data by providing IDataProvider interface and handles pagination and sorting.

It can be used by grids, lists and all other classes extended from CBaseListView as well as in custom code.

In Yii there three default data providers: CActiveDataProvider, CArrayDataProvider and CSqlDataProvider.

Active data provider

CActiveDataProvider implements a data provider based on ActiveRecord.

Array data provider

CArrayDataProvider implements a data provider based on a raw data array.

SQL data provider

CSqlDataProvider implements a data provider based on a plain SQL statement.

Implementing your own custom data provider

In order to implement your own data provider …

Jump to Line
Something went wrong with that request. Please try again.