README.md in postmark-rails-0.5.2 vs README.md in postmark-rails-0.6.0
- old
+ new
@@ -57,15 +57,15 @@
The Postmark gem is compatible with [ActionMailer attachments API](http://api.rubyonrails.org/classes/ActionMailer/Base.html#method-i-attachments). It allows you to specify the name, content-type and other attributes for your attachments.
The legacy `:postmark_attachments` attribute is *no longer supported* on Rails 3.2.13 and above.
-
``` ruby
class TestMailer < ActionMailer::Base
def message_with_attachment
- attachments['42.jpg'] = File.read("/path/to/file")
+ attachments.inline['logo.png'] = File.read("/path/to/image") # Inline image
+ attachments['42.jpg'] = File.read("/path/to/file") # Attached file
mail(
:subject => 'hello',
:to => 'sheldon@bigbangtheory.com',
:from => 'leonard@bigbangtheory.com'
)