Help with gmail message reading with php -


I need to read email from Gmail, but I can not connect to the Gmail POP3 server, anyone can help me here Could?

Code here:

  $ pop3 = new POP3; $ Pop3- & gt; Server = 'pop.gmail.com'; $ Pop3- & gt; User = 'username'; $ Pop3- & gt; Passwd = 'password'; $ Pop3- & gt; Debug = true; $ Pop3- & gt; Pop3_connect ()  

Result:

  WARNING: fsockopen () [function.fsockopen]: Unable to connect to pop.gmail  < According to this page (), you have to use port 995 in Gmail for access to POP3, and besides, SSL should be enabled. 

Wikipedia also:

/ P>

E-mail client of Transport Layer Security (TLS) or Secure Socket Layer (SSL) Using POP3 traffic to encl Using a STLS command, a TLS / SSL connection is negotiated. Some Gmail and Servers, such as Gmail Gmail, use alternate port method, in turn, which can be used for TCP port 995 (POP3S ).


Comments

Popular posts from this blog

c++ - Linux and clipboard -

What is expire header and how to achive them in ASP.NET and PHP? -

sql server - How can I determine which of my SQL 2005 statistics are unused? -