Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- include("pop3.php");
- $host="pop.chinaren.com";
- $user="boss_ch";
- $pass="026007";
- $rec=new pop3($host,110,2);
- if(!$rec->open()) die ($rec->err_str);
- echo "open";
- if(!$rec->Login($user,$pass)) die($rec->err_str);
- echo "login";
- if(!$rec->stat()) die($rec->err_str);
- echo "total:".$rec->messages."mails,total:".$rec->size."bytes<br>";
- if($rec->message>0)
- {
- if(!$rec->listmail()) die($rec->err_str);
- echo "mails as below:<br>";
- for($i=1;$i<=count($rec->mail_list);$i++)
- {
- echo "mail:".$rec->mail_list[$i][num]."size:".$rec->mail_list[$i][size]."<br";
- }
- $rec->getmail(1);
- echo "mail header:<br>";
- for($i=0;$i<count($rec->head);$i++)
- {
- echo htmlspecialchars($rec->head[$i])."<br\n";
- echo "mail contend:<br>";
- for($i=0;$i<count($rec->body);$i++)
- {
- echo htmlspecialchars($rec->body[$i])."<br>\n";
- }
- }
- $rec->Close();
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement