We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

Simple S3 Upload Extension now on EE2 (current version: 1.2.1)

Development and Programming

ender's avatar
ender
1,644 posts
15 years ago
ender's avatar ender

sounds like a really cool setup. I’ve been wanting to create a live demo of what can be done with the add-on but I haven’t had the time yet (been working mostly on an EE 2 port… shhhh!). a tutorial would be awesome too. 😊

       
agrublev's avatar
agrublev
15 posts
15 years ago
agrublev's avatar agrublev

You know the one feature all of the S3 plugins/extensions for EE are missing is the generation of an expiring link. Currently it provides you with a direct link to your s3 bucket file. As you may know Amazon provides you with expiring links that can be generated on the fly, is that something you would consider adding?

       
ender's avatar
ender
1,644 posts
15 years ago
ender's avatar ender

I have been considering adding this, but until now nobody had asked for it.

It isn’t quite trivial to add because I’d need to add some permission settings in order to lock down the bucket and/or files from public view, but it is very doable.

       
agrublev's avatar
agrublev
15 posts
15 years ago
agrublev's avatar agrublev

Interesting i had foolishly thought that amazon will generate links for you that just have random strings, now i realize that the files general permissions will need to be set to private. Interesting, so i assume the only solution would be to always generate expiring links and just allow people to choose how long those should last. Well if you were to add this feature i would definitely like to help reimburse you for your time spent financially 😉

       
ender's avatar
ender
1,644 posts
15 years ago
ender's avatar ender

If you want to chat about how you’d like to see this work or any other thoughts you have on the matter, hit me up via Skype or PM. I’d like to hear what you’re thinking, maybe compare notes.

       
Fred Carlsen's avatar
Fred Carlsen
42 posts
15 years ago
Fred Carlsen's avatar Fred Carlsen

Am I correct when I assume that file sizes are limited by PHP settings?

       
ender's avatar
ender
1,644 posts
15 years ago
ender's avatar ender

that is correct. they are also optionally limited by the max filesize setting when creating the custom field.

       
ender's avatar
ender
1,644 posts
15 years ago
ender's avatar ender

I’m pleased to announce version 1.2.0 of the Simple S3 Uploader. This version adds a number of cool and useful features:

1) ExpressionEngine 2 support! The EE2 port wasn’t easy or quick, but we made it. We were able to take advantage of a few of EE2’s new features, most notably the improved publish page validation callbacks. Now when an upload fails you’ll have a lot more information about why (what? you mean you didn’t enjoy the blank white page in EE1 when things failed? nonsense…).

2) Buckets can be created in different S3 regions. Pretty self-explanitory.

3) A new setting that allows you to specify that all files uploaded to a custom field will be private. This means Joe Public cannot navigate directly to your file on S3 to download it, or hotlink it on another site that drives your bandwidth costs up, etc.

3a) New output functions for S3 authenticated urls. When a file is uploaded as private you’ll need a new way to give people access to it. Now you can generate links to your files that expire after a certain amount of time. The link is authenticated using your S3 account (since you own the files) and is good for the number of minutes you specify in the tag parameter (default 60). This link can also use SSL (https) if you need to have it be encrypted during download (also useful if you need to use images stored on S3 on a secure page… browsers show warnings if you include non-secure items on a secure page).

We also (finally) documented the fieldtype settings over here: http://www.emarketsouth.com/add-ons/simple-s3-uploader/settings/. Sorry about the lack of explanation there! 😕

Enjoy 😊

       
Jedidiah's avatar
Jedidiah
24 posts
15 years ago
Jedidiah's avatar Jedidiah

Just bought this from Devotee and excited to give it a go but having trouble getting it setup,

It installed ok but when adding a new custom field it returns:

An Error Was Encountered S3::listBuckets(): [InvalidAccessKeyId] The AWS Access Key Id you provided does not exist in our records.

I’ve double checked the KeyID and Secret key and have issued a new set, but no luck. I’ve tried with new bucket names and with an existing bucket. Not sure what else to try.

I’m running the latest version in EE2.

       
ender's avatar
ender
1,644 posts
15 years ago
ender's avatar ender

hmm… if you use those same keys through say S3Fox does it allow you to access your buckets?

If that works, does your server meet the requirements? PHP 5 with cURL support is necessary for this add-on. You can find this out by going to your control panel and selecting Tools > Utilities > PHP Info. The PHP version will be near the top of the page and you should be able to search for the text “cURL support” on the page to see if you’ve got that running.

I’m pretty sure that you meet the requirements because you’d most likely get a PHP syntax error trying to use it on PHP 4 and you probably wouldn’t get the response from Amazon S3 in the first place if you didn’t have curl… so I’m not entirely sure what the problem is if your credentials are working.

       
Jedidiah's avatar
Jedidiah
24 posts
15 years ago
Jedidiah's avatar Jedidiah

Thanks for the reply, I use the same key in Transmit and it works fine. I checked the PHP info and you were correct, I’ve got PHP5 and curl.

libcurl/7.15.5 OpenSSL/0.9.8b zlib/1.2.3 libidn/0.6.5

My secret key has a “/” and a “+” in it, guessing that isn’t a problem but not sure what else to check.

       
Jedidiah's avatar
Jedidiah
24 posts
15 years ago
Jedidiah's avatar Jedidiah

Tried it again and it is fine. I found an old thread on the amazon forums where people where having similar issues with newly created aws accounts. So I’m guessing the problem was on their end.

Thanks for the help. =)

       
ender's avatar
ender
1,644 posts
15 years ago
ender's avatar ender

glad it’s resolved itself for you. hope you enjoy it! 😊

       
Andrew Macpherson's avatar
Andrew Macpherson
38 posts
15 years ago
Andrew Macpherson's avatar Andrew Macpherson

I am thinking about buying this add-on, but first I’d like to know whether or not it can add custom headers on upload. I would really like to be able to set Cache-Control headers, for example, preferably on a file-by-file basis if possible but even having a default setting might be enough.

Thanks in advance for any help you can give. Andrew Macpherson Sydney, Australia

       
ender's avatar
ender
1,644 posts
15 years ago
ender's avatar ender

Thanks for the question/feature request. I just implemented a setting which will allow the cache control header to be set and uploaded the new version (1.2.1) to devot://ee.

Best regards, -Ty

       
1 2 3

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.