PHP IMAP not fetching records from cpanel roundcube inbox

476 Views Asked by At

Screenshot

Connection timed out when tried to fetch emails from the cpanel roundcube. All credentials are perfect and hostname and server also working fine.

$hostname = '{mail.server.com:993/novalidate-cert/imap/ssl}';
$username = 'username';
$password = 'password';

$stream = imap_open($hostname, $username, $password) or die('Cannot connect: ' . imap_last_error());
print_r(imap_errors());

Can anyone help please? Thank you

0

There are 0 best solutions below