BE_SMTP_AddAttachment

BE_SMTP_AddAttachment ( { attachment ; contentType } )

Stores a list of attachment files as attachments for future SMTP_Send functions.

Version : 3.3

Version : 4.0 Changed the container parameter to attachment and added the contentType parameter.  Use the OS temp directory when running under FMS.

Parameters : 
attachment : a container field or a path to a file.
contentType : a mime content type, examples below.

 

Use this function to add attachments to an outgoing email that would normally be sent via SMTP Send, but are not on disk.  You can add multiple attachments by calling this multiple times.  Once SMTP_Send is done it clears out the list of stored attachments regardless of the success of the Send.

Attachments are actually written to disk by the plugin, to the users temp folder, so this does require you to have access to a working temp folder ( defined by the OS ).

 

Result : 0 for success or ? for an error.

 

Notes : The content type is what is set in the mime type for emails.  So usually something like :

Content-Type: application/pdf; charset=UTF-8
Content-Type: text/plain; name="file.txt"
Content-Type: application/octet-stream; name="file.pdf"

 

Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.