rogeriopradoj/codeigniter-restclient
Composer 安装命令:
composer require rogeriopradoj/codeigniter-restclient
包简介
codeigniter-restclient philsturgeon's library via composer
README 文档
README
CodeIgniter-REST Client is a CodeIgniter library which makes it easy to do use REST services/API's such as Twitter, Facebook and Flickr, whether they are public or hidden behind HTTP Basic/Digest.
Requirements
- PHP 5.1+
- CodeIgniter 2.0.0+
- cURL
- CodeIgniter Curl library: http://getsparks.org/packages/curl/show
Usage
// Load the rest client spark
$this->load->spark('restclient/2.1.0');
// Load the library
$this->load->library('rest');
// Run some setup
$this->rest->initialize(array('server' => 'http://twitter.com/'));
// Pull in an array of tweets
$tweets = $this->rest->get('statuses/user_timeline/'.$username.'.xml');
This is clearly a VERY simple example and more can much more can be done with it. Take a look at the code to see about things like api_key() and other post/put/delete methods.
统计信息
- 总下载量: 2.02k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 2
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: Unknown
- 更新时间: 2013-05-27