Mohl by mi někdo poradit kde mám chybu v tomto kódu?
<?php
$connection = imap_open("{imap.gmail.com:993/imap/ssl}INBOX", "uzivatel@gmail.com", "heslo");
$num_mgs = imap_num_msg($connection);
imap_close($connection);
echo "$num_msg";
?>
Pokud tento script spustím tak obdržím:
Warning: imap_open(): Couldn't open stream {imap.gmail.com:993/imap/ssl}INBOX in c:\php\webmail\prihlasit.php on line 2
Warning: imap_num_msg(): supplied argument is not a valid imap resource in c:\php\webmail\prihlasit.php on line 3
Warning: imap_close(): supplied argument is not a valid imap resource in c:\php\webmail\prihlasit.php on line 4
Notice: Undefined variable: num_msg in c:\php\webmail\prihlasit.php on line 5
Notice: (null)(): Can't open mailbox {imap.gmail.com:993/imap/ssl}INBOX: invalid remote specification (errflg=2) in Unknown on line 0