psugand / CodeIgniter-S3

Amazon S3 Library for CodeIgniter
http://prashant.es
241 stars 115 forks source link

h1. Amazon S3 Library for CodeIgniter

Easily integrate your CI applications to Amazon's Simple Storage Solution with this library.

This library is (hardly) a port of "Donovan Schönknecht's S3 PHP Class":http://undesigned.org.za/2007/10/22/amazon-s3-php-class.

h2. Setup

Edit config/s3.php with your appropriate settings

Copy config and library files to your CI installation

h2. Class Methods

For more detailed information about the required parameters and returns check the S3.php file.

h3. Objects:

h3. Buckets:

h3. Access Control Policies:

h3. CloudFront:

h3. Legacy methods:

h2. Example Usage


  // Load Library
  $this->load->library('s3');

  // Create a Bucket
  var_dump($this->s3->putBucket('My-Bucket', $this->s3->ACL_PUBLIC_READ));

  // List Buckets
  var_dump($this->s3->listBuckets());

h2. References