Forum Moderators: coopster

Message Too Old, No Replies

deleting emails with imap

my emails just stay around

         

meingallsphp

2:11 am on Apr 25, 2007 (gmt 0)

10+ Year Member



I open the email box with imap_open(), process the emails, then mark each one for deletion with imap_delete(). Then I close the connection with imap_close($box,CL_EXPUNGE). But the emails do not get deleted.

I tried putting an imap_expunge() command in prior to the imap_close() call, but that didn't do the trick either.

Any suggestions?

Thanks,

Mel

eelixduppy

1:46 pm on Apr 26, 2007 (gmt 0)



imap_expunge should do the trick if the messages were properly marked for deletion. Are you receiving any error messages from this script? From the information you are giving it seems that everything should be working fine.