Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

s3-bucket-url-update #28

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions extension.meta.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@
</author>
</authors>
<releases>
<release version="0.9.3" date="2019-05-24" min="2.3.1" max="2.x.x">
* S3 URL updated to use bucket subdomain rather than sub folder. New requirement from AWS.
</release>
<release version="0.9.2" date="2018-04-09" min="2.3.1" max="2.x.x">
* Remove use of `/e` modifier for PHP 7 compatibility
</release>
Expand Down
2 changes: 1 addition & 1 deletion fields/field.s3upload.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ private function getUrl($file)
$protocol = ($this->get('ssl_option') == true ? 'https://' : 'http://');

if ($this->get('cname') == '') {
$url = $protocol . "s3.amazonaws.com/" . $this->get('bucket') . "/" . $file;
$url = $protocol . $this->get('bucket') . ".s3.amazonaws.com/" . $file;
}
else {
$url = $protocol . $this->get('cname') . "/" . $file;
Expand Down