RubyFlow The Ruby and Rails community linklog

×

The Ruby and Rails community linklog

Made a library? Written a blog post? Found a useful tutorial? Share it with the Ruby community here or just enjoy what everyone else has found!

Fix the content-type for file uploads with the rack-fix-content-type gem

We wrote the rack-fix-content-type gem to fix the content type of form uploads (by using the file-utility). A lot of browsers screw up the content type so we don’t trust the given value in the header. We had a couple of different content-types for each type of uploaded file which can create a lot of trouble (for example when using the content-type in mail attachments).

Post a comment

You can use basic HTML markup (e.g. <a>) or Markdown.

As you are not logged in, you will be
directed via GitHub to signup or sign in