Skip to content

Instantly share code, notes, and snippets.

@newbdez33
Forked from millsy/fileurl.php
Created November 13, 2012 08:31
Show Gist options
  • Save newbdez33/4064665 to your computer and use it in GitHub Desktop.
Save newbdez33/4064665 to your computer and use it in GitHub Desktop.
amazon s3 php get url of file
<?php
require_once 'sdk.class.php';
$s3 = new AmazonS3();
$s3url = $s3->get_object_url('mybucket', 'mypath/tofile.txt', '5 minutes');
echo $s3url;
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment