king.oslo Posted January 11, 2010 Share Posted January 11, 2010 Hello my friends, I am writing an online emailing application with inbox outbox/sent elements etc. When I send and email with mail() function, what would I do in order to save to the sent elements? Thanks, Marius Link to comment https://forums.phpfreaks.com/topic/187988-imap-how-to-save-a-copy-of-sent-emails-to-sent-elements/ Share on other sites More sharing options...
jeremy0 Posted January 11, 2010 Share Posted January 11, 2010 king: You are writing basically an email server, right? You would have to store the pieces of the email somewhere in the database, and then display those to that user and associate them with their account. i.e. 1. User sends email: a. subject b. body c. to d. from ...etc. 2. Store copy of email in database 3. Send email to 'to' address 4. If user clicks on 'sent' folder a. hit the database and look for the emails user sent b. display list of emails. if user deletes permenantly, remove from database. Obviously, there's probably a lot more that needs to happen for a full email server, but you get the idea - you would need to store the pieces of the email in the database and piece them back together later. The real fun starts when/if you need to receive emails from another email server or make use of the different kinds of emails that might be interacted with.. Link to comment https://forums.phpfreaks.com/topic/187988-imap-how-to-save-a-copy-of-sent-emails-to-sent-elements/#findComment-992595 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.