On Tue, Oct 26, 2010 at 12:29 PM, Mike Cochrane <[email protected]> wrote: > Hi Brendan, > > If the email is being received on your own server then there is an > alternative to polling. You can have your email server pass the incoming > messages to a php script for you. > > For me (using postfix/procmail) I create a .forward file in the folder of > the user and add something like: > > "|IFS=' ' && exec /path/to/my/mail/handler/script.php || exit 75 #www-data" > > And all incoming email for that user gets passed to script.php > > - Mike >
+1 this method. Kind Regards, Jochen Daum P.S.: Do you know anyone who wants to rent a desk in our Mt Eden office? http://ow.ly/2Vs5i - no term commitment - fully serviced Chief Automation Officer Automatem Ltd Phone: 09 630 3425 Mobile: 021 567 853 Email: [email protected] Skype: jochendaum Website: www.automatem.co.nz http://twitter.com/automatem http://nz.linkedin.com/in/automatem http://www.xing.com/go/invite/3425509.181107 http://www.aucklandbusinessnetworking.co.nz > > On 26/10/2010 11:57, Brendan Brink wrote: > > Hi there, > > Wanting to accomplish the following: > > 1. Setup a special email address at my domain. > 2. Using PHP, poll the email address inbox for unread emails every 5 > minutes or so (using CRON job) > 3. If there is an email extract the attachment on the email and save > as a file on the server. > 4. Mark the email as read. > > Anyone had any experience or has a good tutorial on how to do this > correctly? > > Cheers > Brendan. > > > -- > NZ PHP Users Group: http://groups.google.com/group/nzphpug > To post, send email to [email protected] > To unsubscribe, send email to > [email protected] -- NZ PHP Users Group: http://groups.google.com/group/nzphpug To post, send email to [email protected] To unsubscribe, send email to [email protected]
