User Guide

Table Of Contents
Handling POP mail 989
MessageNumber: #HTMLEditFormat(Sample.MessageNumber)# <br>
To: #HTMLEditFormat(Sample.to)# <br>
From: #HTMLEditFormat(Sample.from)# <br>
Subject: #HTMLEditFormat(Sample.subject)# <br>
Date: #HTMLEditFormat(Sample.date)# <br>
Cc: #HTMLEditFormat(Sample.cc)# <br>
ReplyTo: #HTMLEditFormat(Sample.ReplyTo)# <br>
Attachments: #HTMLEditFormat(Sample.Attachments)# <br>
Attachment Files: #HTMLEditFormat(Sample.AttachmentFiles)# <br>
<br>
Body:<br>
#Sample.body# <br>
<br>
Header:<br>
HTMLCodeFormat(Sample.header)# <br>
<hr>
</cfoutput>
</body>
</html>
2.
Edit the following lines so that they refer to valid values for your POP mail server, username,
and password:
<cfpop server="mail.company.com"
username=#myusername#
password=#mypassword#
3.
Save the file as header_body_att.cfm in the myapps directory under your web_root and view it
in your web browser:
Note: To avoid duplicate filenames when saving attachments, set the generateUniqueFilenames
attribute of
cfpop to Yes.
Deleting messages
Using the
cfpop tag to delete a message permanently removes it from the server. By default,
retrieved messages remain on the POP mail server. To delete the messages, set the
action
attribute of the
cfpop tag to Delete. Specify use the messagenumber attribute to specify the
messages to delete; omit the attribute to delete all the user’s messages from the server.
Note: Message numbers are reassigned at the end of every POP mail server communication that
contains a delete action. For example, if you retrieve four messages from a POP mail server, the
server returns the message numbers 1,2,3,4. If you delete messages 1 and 2 with a single
cfpop tag,
messages 3 and 4 are assigned message numbers 1 and 2, respectively.