Krystian - 2016-10-27 08:12:38
public function set_move_email($mid=null, $target="INBOX") {
if(!$this->is_connected || is_null($mid))
return false;
return imap_mail_move($this->marubox,$mid, $target);
}
public function get_number_of_unread()
{
if(strtolower($this->protocol) != 'imap') {
echo "Warning: The function get_number_of_unread will not work on '".$this->protocol."' Protocol";
return false;
}
if(!$this->is_connected)
return false;
$result = imap_search($this->marubox, 'UNSEEN');
if (is_array($result)) return count($result);
else return 0;
}