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

Wrong content setting on files uploaded to s3 via stream wrapper #23

Open
teu opened this issue Aug 8, 2013 · 2 comments
Open

Wrong content setting on files uploaded to s3 via stream wrapper #23

teu opened this issue Aug 8, 2013 · 2 comments

Comments

@teu
Copy link

teu commented Aug 8, 2013

Hi,

good work on the bundle first of all, the cdn setup is comprehensive and easy to follow. One problem I ran into trying to upload my assets to S3 is their content type. All assets should have different content types but they turn out to have

application/octet-stream

which is a problem, becase the browser doesn't interpret them correctly and keeps generating errors. Any way to remedy this?

Thanks

@mbadolato
Copy link
Contributor

I'm not familiar enough with S3 to be able to answer that, unfortunately. My assumption would be that there's possibly something in the SDK documentation for the S3 service that would allow you to set the type.

Just grepping for octet-stream in the sdk lib I find:

``vendor/amazonwebservices/aws-sdk-for-php/extensions/s3browserupload.class.php: *

  • Content-Type - string - Optional - The Content-Type HTTP header value to apply to the uploaded file. The default value is application/octet-stream.`

    So it looks like it's settable

  • @teu
    Copy link
    Author

    teu commented Aug 8, 2013

    Well, yes it is, but setting it by hand is very much against the automatic deployment process. Will research some more, Thanks for your help.

    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    None yet
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants