/** * _getFeeds Get unread google reader items * * @return void */ private function _getFeeds() { $googleReader = new GoogleReaderAPI(Yii::app()->params['credentials']['googleReader']['username'], Yii::app()->params['credentials']['googleReader']['password']); //get first 10 unread items from google reader $unreadItems = $googleReader->get_unread(10); //CVarDumper::dump($unreadItems, 10, true);die; return $unreadItems->items; }
public function run($id) { $googleReader = new GoogleReaderAPI(Yii::app()->params['credentials']['googleReader']['username'], Yii::app()->params['credentials']['googleReader']['password']); $googleReader->set_state($id, 'read'); echo json_encode(array('status' => 200)); }
public function actionDebug() { $googleReader = new GoogleReaderAPI(Yii::app()->params['credentials']['googleReader']['username'], Yii::app()->params['credentials']['googleReader']['password']); $unreadItems = $googleReader->get_unread(10); CVarDumper::dump($unreadItems, 10, true); }