Quantcast
Channel: Yii Framework Forum
Viewing all articles
Browse latest Browse all 18717

Class 'cdataprovider' Not Found

$
0
0
I'm attempting to use a GridView to display and paginate records retrieved from an API. Since the API returns the records as an array, I'm using the ArrayDataProvider. my data provider looks like this:

$dataProvider = new CArrayDataProvider($arrayData,  array(
                                'keyField'=>'user_id',
                                'sort'=>array(
                                'attributes'=>array('user_id'),
                                'defaultOrder'=>array('user_id' => false),
                        ),
                                'pagination'=>array(
                                'pageSize'=>10,
                        ),
));


But which gives me an error "Class 'CArrayDataProvider' not found in ..\protected\controllers\MagentoController.php on line 17". If I include CArrayDataProvider.php file in the top of controller, i'm getting error like this "Class 'CDataProvider' not found in ..\protected\extensions\CArrayDataProvider\CArrayDataProvider.php on line 19"

Viewing all articles
Browse latest Browse all 18717

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>