NAME

IX::Email - environment-sensitive email sending from IX


SYNOPSIS

  use IX::Email;
  
  IX::Email::send(
        to       => 'user@domain.com', 
        reply_to => 'anotheruser@domain.com', 
        subject  => 'Test Email', 
        body     => 'Dear So and So...',
        attach   => $attachment,
  );


REQUIREMENTS

Requires Sys::Hostname, MIME::Lite, and File::Type.


METHODS

saveAttachment()

Saves an uploaded file from a multipart form to the filesystem and records it in the 'attachments' table. Precursor to using IX::Email::send with an attachment, as above.

send()

Sends an email.

updateLastBulkSendSession()

Sets a flag in the 'users' table with the IX::Session::cgi_session->id to allow only one bulk email send per logged-in session.