Skip to content

alyahmmed/CodeIgniter-S3-Upload

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

Amazon S3 Upload Library for CodeIgniter

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

Setup

  1. Create Amazon S3 account
  2. Create a bucket for the files
  3. Get Amazon S3 API key and secret
  4. Edit config/s3.php with your appropriate settings
  5. Copy config and library files to your CI installation

Example Usage


  // Load Library
  $this->load->library('s3_upload');
  
  // Upload file
  $sample_file = APPPATH.'public/img/apple.gif';
  $file_url = $this->s3_upload->upload_file($sample_file);

  var_dump($file_url);
  // string(56) "https://bucket-name.s3.amazonaws.com/files/apple-561.gif"

References

About

CI library for Amazon’s S3 upload

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages