How do you add an email filter to an IMAP email account?

萝らか妹 提交于 2019-12-25 06:26:35

问题


I'm using PHP (zend_mail_storage_imap specifically). I built the first iteration of an email product a few days ago. Basically, I flag and filter a number of emails using zend_mail and an imap email account. The problem is that I'm currently searching the email address every five minutes to see if a new email was received. I'd like to change this by placing a filter in IMAP itself - a filter similar to GMAIL filters. Would this be possible to set this up directly in IMAP? If not, what would be the next best solution?

My main problem is that although I can filter emails, they still get "pushed" to my blackberry storm before they get filtered out every five minutes.


回答1:


There is currently a proposal for an IMAP extension that would permit clients to update their Sieve rules via IMAP. But it's still in the draft stage and, to my knowledge, has only been implemented by the Cyrus IMAP server. So, in general, you're probably out of luck.

There's also a new protocol for remotely managing Sieve scripts. I'm not sure how widely supported it is yet, and your mail server may not support it. I'm also not aware of a popular PHP client for it, so you may need to try out some beta software or roll your own.



来源:https://stackoverflow.com/questions/4445878/how-do-you-add-an-email-filter-to-an-imap-email-account

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!