Forum Moderators: coopster

Message Too Old, No Replies

Email photos to folder

         

kreativity

4:42 am on Jan 21, 2008 (gmt 0)

10+ Year Member



Greetings.

Basically what i'm trying to do is set up a script that will look for new messages in a specified email account, extract the images and add them to a folder. This is somewhat similar to the Wordpress "Blog by Email" function.

My goal for this script is to allow updating of SimpleViewer by email. I would set up cron to run the script regularly and run the SimpleViewer update script. That way, I could email photos to my website and they would be automatically added to the SimpleViewer gallery.

Any ideas?

Thanks

venelin13

6:28 am on Jan 21, 2008 (gmt 0)

10+ Year Member



You can read the emails and their attachments, using the IMAP [php.net] functions family.

You should either set a separate email account to which you want to send the messages or use some predefined string at the subject line, so your PHP script can easly detect which messages from your mail box to process.

You should set a cron job to check your mail account regular.