Re: trouble trying to connect to gmail server.

From: Date: Tue, 25 Sep 2007 02:22:42 +0000
Subject: Re: trouble trying to connect to gmail server.
References: 1 2 3 4  Groups: php.general 
Request: Send a blank email to php-general+get-262436@lists.php.net to get a copy of this message
Array ( [0] => Host not found (#11001): pop3.gmail.com )
So pop3.gmail.com doesn't exist.
<? $mbox = imap_open('{pop.gmail.com:995/pop3}INBOX<http://pop.gmail.com:995/pop3%7DINBOX>', '<my_login>@gmail.com', <my_pass>'); print_r(imap_alerts()); print_r(imap_errors()); $num_mens_not_read = imap_num_recent($mbox); imap_close($mbox); ?> I get these errors: Warning: imap_open(): Couldn't open stream { pop.gmail.com:995/pop3}INBOX<http://pop.gmail.com:995/pop3%7DINBOX>in c:\arquivos de programas\easyphp1-8\www\index.php on line 4 Fatal error: Maximum execution time of 30 seconds exceeded in c:\arquivos de programas\easyphp1-8\www\index.php on line 4 Notice: (null)(): POP3 connection broken in response (errflg=2) in Unknown on line 0 This second code looks like ok for me, but for some reason I get this time out. Do you have any idea what's going on? Did I miss some configuration?
Line 4 is $num_mens_not_read = imap_num_recent($mbox); so it's taking too long to work out how many are recent. How many unread messages are there in your account? How many messages in total? -- Postgresql & php tutorials http://www.designmagick.com/

« previous php.general (#262436) next »