Laminias mail pop imap not working

Hello,

Where is the error on this codes :

use Laminas\Mail\Storage\Pop3;
require_once 'vendor/autoload.php';

$mail = new Pop3([
    'host'     => 'pop.gmail.com',
    'user'     => 'xxxxxxxx@gmail.com',
    'password' => 'xxxxxxx',
	'port' => '995',
	'ssl' => 'TLS'
]);

echo $mail->countMessages() . " messages found\n";
foreach ($mail as $message) {
    printf("Mail from '%s': %s\n", $message->from, $message->subject);
}

thx

Are you getting an error message or what exactly is the problem?

You may also have to allow POP3 first, but you should rather use IMAP than POP3 anyway.