In the parse_message.php file, it has an example that saves the emails to 1, 2, etc. This example only ever pulls one email down at a time. I've tried wrapping that code into a loop, but it only ever gives me 1 email, regardless of how many I actually have in that mailbox.
Is there a way to use that same code to download all of the email from the mailbox?
Manuel Lemos - 2007-03-07 19:22:57 - In reply to message 3 from Patrick Waddingham
First, open the POP3 connection as usual. Then for each message that you want to receive, use the OpenMessage function to start reading the message, and the GetMessage function repeatedly to retrieve the message data into a string until it reaches the end of message.
If you want to parse the messages, you need to call the MIME parser class Decode function, using the Data parameter to pass the message string. Do not specify the File parameter as you no longer be reading the message from a stream.