note 43358 deleted from function.imap-bodystruct by didou
| From: | didou@php.net | Date: | Tue, 31 Aug 2004 00:59:38 +0000 |
| Subject: | note 43358 deleted from function.imap-bodystruct by didou | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-75699@lists.php.net to get a copy of this message | ||
Note Submitter: giraldo at nitrogendesign dot com
----
Actually in that last code replace the "1" to "$i" so it should look like the
following:
function getAttachments($mbox,$msgNum){
$structure = imap_fetchstructure($mbox,$msgNum);
$contentParts = count($structure->parts);
if($contentParts > 1){
for($i=1; $i<=$contentParts; $i++){
if($structure->parts[$i]->type > 0){
$attachments .= $structure->parts[$i]->description;
}
}
}
return $attachments;
}