X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=src%2Fdownload.php;h=f8a334d180b98465c4ba92fd0e356e109034d43a;hb=abddc974c228ad2762c276ad68778dde7cdfeabf;hp=6aa7a89535a8276fd120a744bb33bc0dca556fe4;hpb=b235d62915dba943446744b725971bd2c47bc347;p=squirrelmail.git diff --git a/src/download.php b/src/download.php index 6aa7a895..f8a334d1 100644 --- a/src/download.php +++ b/src/download.php @@ -1,11 +1,16 @@ "; } - $imapConnection = loginToImapServer($username, $key, $imapServerAddress, 0); - selectMailbox($imapConnection, $mailbox, $numMessages); + $imapConnection = sqimap_login($username, $key, $imapServerAddress, 0); + sqimap_mailbox_select($imapConnection, $mailbox); // $message contains all information about the message // including header and body - $message = fetchMessage($imapConnection, $passed_id, $mailbox); + $message = sqimap_get_message($imapConnection, $passed_id, $mailbox); $type0 = $message["ENTITIES"][$passed_ent_id]["TYPE0"]; $type1 = $message["ENTITIES"][$passed_ent_id]["TYPE1"]; @@ -79,5 +84,5 @@ } } - fputs($imapConnection, "1 logout\n"); + sqimap_logout($imapConnection); ?>