Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env ruby
- require 'rubygems'
- require 'postmark'
- require 'tmail'
- require 'readhtml.rb'
- Postmark.api_key = "70b6a082-2f01-48c8-ba30-ff3e772c2845"
- message = TMail::Mail.new
- message.from = "igor@wildbit.com"
- message.to = "ibalosh@gmail.com"
- #message.cc = "ibalosh@aol.com, ibalosh@yahoo.com"
- #message.bcc = "ibalosh+bcc@hotmail.com"
- message.subject = "test"
- message.content_type = "multipart/alternative"
- message.body = read_file("template.html")
- message.tag = "java"
- #message.postmark_attachments = [File.open("template.html")]
- # staging setup end
- for i in 1..1 do
- puts "Email:" + i.to_s
- puts Postmark.response_parser_class.inspect
- p Postmark.send_through_postmark(message)
- end
Add Comment
Please, Sign In to add comment