title: upload files to amazon s3 directly with php
body: <p>solved: using this post :  <a href="http://www.designedbyaturtle.co.uk/2013/direct-upload-to-s3-with-a-little-help-from-jquery/" rel="nofollow noreferrer">http://www.designedbyaturtle.co.uk/2013/direct-upload-to-s3-with-a-little-help-from-jquery/</a></p>
  
  <p>edit: I'm looking for a way to directly upload a big zip file from client side to amazon s3 without first uploading it to my server</p>
  
  <p>I'm using a small server for my web application with laravel framework
  I have some users trying to upload big files to my servr (around 300-400m), and my server is to weak and my bandwidth is to low for the user to be able to finish uploading.</p>
  
  <p>I want the file to be uploaded directly to amazon s3,
  from browsing around i dont think this can be dont with laravel sdk for amazon</p>
  
  <p>I installed the official sdk
  and I'm trying to do it like suggested in this post
  <a href="https://stackoverflow.com/questions/22224724/uploading-posted-file-to-amazon-s3/27680430#27680430">uploading posted file to amazon s3</a></p>
  
  <p>but not rally sure how to actually send my file to amazon s3,
  what should i put instad of 'string of your file here':</p>
  
  <pre><code> $result = $client-&gt;upload(
  'BUCKET HERE',
  'OBJECT KEY HERE',
  'STRING OF YOUR FILE HERE',
  'public-read' // public access ACL
  );
  </code></pre>
  
  <p>im getting my file like this :</p>
  
  <pre><code>$myFile = Input::file('file');
  </code></pre>
  
  <p>putting $myfile instead of 'string of your file here' doesnt work</p>