- Timestamp:
- 09/24/12 10:31:10 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2.4/expressoMail1_2/inc/class.imap_functions.inc.php
r7236 r7281 3651 3651 return $returns; 3652 3652 } 3653 function verify_disposition_notification($msg){ 3654 $header = imap_fetchheader($this->mbox, $msg, FT_UID); 3655 $pattern = '/^[ \t]*Disposition-Notification-To:.*/mi'; 3656 if (preg_match($pattern, $header, $fields)) 3657 return true; 3658 else 3659 return false; 3660 } 3661 3653 3662 function set_messages_flag($params) 3654 3663 { … … 3677 3686 $msgs = explode(",",$msgs_to_set); 3678 3687 foreach($msgs as $men){ 3679 if (imap_setflag_full($this->mbox, $men, "\\Seen", ST_UID)) 3680 $return["msgs_to_set"] .= $men.","; 3681 else 3682 $return["msgs_not_to_set"] .= $men.","; 3688 3689 if($this->verify_disposition_notification($men)){ 3690 3691 if(!array_key_exists('disposition_notification_to', $return)) 3692 $return['disposition_notification_to'] = array(); 3693 3694 $return["disposition_notification_to"][] = $men; 3695 }else{ 3696 if (imap_setflag_full($this->mbox, $men, "\\Seen", ST_UID)) 3697 $return["msgs_to_set"] .= $men.","; 3698 else 3699 $return["msgs_not_to_set"] .= $men.","; 3700 } 3683 3701 } 3684 3702 $return["status"] = true;
Note: See TracChangeset
for help on using the changeset viewer.