Thank you dude, for your respond.
1.>letter = Newsletter.find(params[:id])
2.>users = UserProfile.find(:all)
3.> for member in users
4.> Notifier.deliver_letternews(member, letter)
5.> end
why i do not put email params there because i use several user information like
name and address for email content in def letternews for the Notifier <
ActionMailer::ARMailer
6.> newsletter.update_attribute('sent', true)
7.> @form_display = true
8.> @action = 'update'
9.> @success = 'Newsletter is already sent to your members successfully.'
Line 6 is for record that the message is already sent and can not be used again
for next newsletter.
Line 7 - 8 is configuration only for View like blocking of partial.
Line 9 is message after succesfully sending. I do not use flash because it's
already use for another type of message.
Any suggestion more? about rubyinside.come based of Hendy's written is the same
idea with my code but still never stop sending email (keep looping.)
Sincerely,
Reinhart
http://teapoci.blogspot.com
____________________________________________________________________________________
You rock. That's why Blockbuster's offering you one month of Blockbuster Total
Access, No Cost.
http://tc.deals.yahoo.com/tc/blockbuster/text5.com