How to send mail with High priority


#1

Hi all

 I try to send mail by net::smtp. it works fine.
But I don't know how to send high priority mails.
who can help me for this ?
thanks

sandy


#2

Hi,

2008/11/4 Sandy removed_email_address@domain.invalid:

Hi all

I try to send mail by net::smtp. it works fine.

But I don’t know how to send high priority mails.
who can help me for this ?
thanks

sandy

Add Priority: Urgent and Importance: High headers like this:

Net::SMTP.start(‘smtp.example.com’, 25) do |smtp|
smtp.open_message_stream(‘removed_email_address@domain.invalid’, [‘removed_email_address@domain.invalid’]) do
|f|
f.puts ‘Priority: Urgent’
f.puts ‘Importance: High’
f.puts ‘From: removed_email_address@domain.invalid’
f.puts ‘To: removed_email_address@domain.invalid’
f.puts ‘Subject: test message’
f.puts
f.puts ‘This is a test message.’
end
end

Hope this helps
Park H.


#3

Heesob P. wrote:

Add Priority: Urgent and Importance: High headers like this:

Which are, of course, ignored by virtually every MTA on the planet,
since RFC 2822 does not define these headers, nor the way they should be
handled.

However they might be highlighted with a flag in the receiver’s MUA
though, depending on what MUA they use, and perhaps that’s all you want.

There’s a list of non-standard or experimental headers you can try in
RFC 2076 (see esp. section 3.9)