imap

open email by php using imap giving me this error Message: imap_open() [function.imap-open]: Couldn't open stream {imap.gmail.com:993/imap/ssl}INBOX

末鹿安然 提交于 2019-12-13 05:25:34
问题 I am trying to open the email messages by php using imap method but it give me an error Couldn't open stream {imap.gmail.com:993/imap/ssl}INBOX and this is my code $hostname = '{imap.gmail.com:993/imap/ssl}INBOX'; $username = 'nohamedtemraz92@gmail.com'; $password = '0129799169mohamed'; /* try to connect */ $inbox = imap_open($hostname,$username ,$password) or die('Cannot connect to Gmail: ' imap_last_error()); /* grab emails */ $emails = imap_search($inbox,'ALL'); /* if emails are returned,

Mail sent with PHP mail are not shown in my mails Sent folder

北慕城南 提交于 2019-12-13 03:56:47
问题 I'm sending email from my webmail accounts to any email address. Mails are sending successfully, but how can I have this mails in my webmail account sent folder . I use codeigniter email sent functionality. 回答1: You should include your code in your question. This isn't PHPMailer's job, but it's related. Take a look at the end of the gmail example provided with PHPMailer. It includes a section that uploads a sent message to your IMAP folder. The basic idea is that after you've received a

C++ LibcURL IMAP fetch what is the variable holding the subject line?

Deadly 提交于 2019-12-13 03:18:25
问题 Code is https://curl.haxx.se/libcurl/c/imap-fetch.html In that example what would be variable holding the Subject line be. It prints it out in the console but I would like to be able to compare the content of the subject. For instance if I wanted to: If (subject == "sample text") { Do things; } 回答1: You can use a URL that retrieves only the subject, if that's what you want. curl_easy_setopt(curl, CURLOPT_URL, "imap://imap.example.com/INBOX/;UID=1;SECTION=HEADER.FIELDS%20(Subject)"); Some of

php IMAP connection failed

╄→гoц情女王★ 提交于 2019-12-13 01:50:28
问题 I am developing a crawler to get data from email. I have 3 email addresses, which I have to use for it. On my local machine all of 3 connections with given credentials are working fine. But when I have upload to server 1 of them is working and rest of 2 are giving Can not authenticate to IMAP server: [CLOSED] IMAP connection broken (authenticate) These 3 inboxes are on shared hosting and I using port 143 to read data. In ssh I get this error: Can not authenticate to IMAP server: [CLOSED] IMAP

Error 324 (net::ERR_EMPTY_RESPONSE): Unknown error

梦想的初衷 提交于 2019-12-13 00:28:59
问题 I get the following error in Chrome every time I try to run my script on a Linux server: Error 324 (net::ERR_EMPTY_RESPONSE): Unknown error. In Firefox it just shows a blank white page. Whenever I run it on my local test server (IIS on Windows 7) it runs exactly the way it should with no errors. I am pretty sure that it is a problem with the imap_open function. <?php error_reporting(E_ALL); echo "test"; // enter gmail username below e.g.--> $m_username = "yourusername"; $m_username =

How to get message from MessageIDTerm for Yahoo IMAP profile?

馋奶兔 提交于 2019-12-12 16:43:56
问题 I am trying to get IMAP message from message ID, this case is successful for IMAP server for Gmail i.e imap.gmail.com but same I am trying with Yahoo IMAP server imap.mail.yahoo.com , inbox.search(searArr[0]) is returning null. My code block to get message is - Message[] msgs = null; MessageIDTerm[] searArr = new MessageIDTerm[]{new MessageIDTerm((String) strMessageID)}; if (inbox != null && inbox.isOpen()) { msgs = inbox.search(searArr[0]); } for (int i = 0; i < msgs.length; i++) { System

IMAP client library in Erlang to query IMAP servers [closed]

白昼怎懂夜的黑 提交于 2019-12-12 14:16:08
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 4 years ago . Is there any working IMAP client library implemented in Erlang which can query IMAP servers? 回答1: erlmail easily found on google 回答2: there is another one erlimap. But work is in progress. 来源: https://stackoverflow.com/questions/2866956/imap-client-library-in-erlang-to-query-imap-servers

How to search mails from mailbox using Subject line

旧城冷巷雨未停 提交于 2019-12-12 10:16:26
问题 I am using IMAP to read a mailbox. Now is it possible that I can search mailbox with SUBJECT LINE and FROM name as flag ? Example : is it possible to define search criteria : imap_search($login,'SUBJECT '.$sub.' FROM'.$ToSearch) ; Is it allowed to use from name and subject in search for an email ? 回答1: See the SEARCH Command section of RFC 3501 to see how to use search functionality in IMAP. An AND operation is implicit so you can just put conditions next to each other: 0001 SEARCH SUBJECT

PHP imap download attachment

本小妞迷上赌 提交于 2019-12-12 09:14:44
问题 Below I am looping through emails, using PHPs imap libraries. It works, but I'm stuck on saving attachments from the message. <?php $hostname = '{imap.gmail.com:993/imap/ssl}INBOX'; $username = 'someemail@somedomain.com'; $password = 'somepassword'; /* try to connect */ $imap_connection = imap_open($hostname,$username,$password) or die('Cannot connect to Gmail: ' . imap_last_error()); /* grab emails */ $emails = imap_search($imap_connection,'ALL'); /* if emails are returned, cycle through

How to get gmail threadid using imap xoauth

…衆ロ難τιáo~ 提交于 2019-12-12 08:45:30
问题 I read this Find Gmail url-IDs via IMAP, but I noticed Greplin (https://www.greplin.com) is able to get thread id successfully. Can anyone help me here? Regards, Manoj 回答1: Gmail provides An attribute "X-GM-THRID" for thread id you can use imap fetch function for getting thread id . see documentation here http://code.google.com/apis/gmail/imap/ 回答2: I think that is can be access via libgmailer.php (curl) http://sourceforge.net/search/?q=libgmailer 来源: https://stackoverflow.com/questions