tags:

views:

33

answers:

1

I've been receiving a lot of spam emails and I want to post them on my website to serve as a warning for others not to believe it. Since I'm too lazy to login to my email account and check. I'm thinking to write a script in php (since this is the only one i know)that logs in to the mailbox at regular intervals, retrieves the content of the e-mails and then post it to my website automatically. Any suggestions on what would be the best approach to accomplish this task? Do I have to do PHP socket programming?

Thanks

+1  A: 

I suppose your emails are filed under a Spam or Junk folder. You may want to set up a Cron job that runs periodically to read via IMAP or POP.

You may want to check what're the protocols supported by your service provider and where exactly you want to post the information to - a database or HTTP POST.

yclian