PHP code example of booosta / imap
1. Go to this page and download the library: Download booosta/imap library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
booosta / imap example snippets
$msg = $imap->get_mail_message($number);
print PHP_EOL . 'Sender: ' . $msg->get_sender();
print PHP_EOL . 'Recepient: ' . $msg->get_recepient();
print PHP_EOL . 'Recepient: ' . $msg->get_recipient(); // for those always typing it wrong ;-)
print PHP_EOL . 'Subject: ' . $msg->get_subject();
print PHP_EOL . 'Text: ' . $msg->get_text();
print PHP_EOL . 'Raw Text: ' . $msg->get_rawtext();
print PHP_EOL . 'Date/Time: ' . $msg->get_dtime();