note 106069 added to function.imap-fetchstructure

From: Date: Fri, 07 Oct 2011 11:12:46 +0000
Subject: note 106069 added to function.imap-fetchstructure
Groups: php.notes 
Request: Send a blank email to php-notes+get-183701@lists.php.net to get a copy of this message
Update for david at hundsness dot com 12-Sep-2008 08:00. Hi David, First of all, you code it's great. Thanks a lot. Secondly, there is a small bug in the subpart recursion code block. I tried your code on an email which has been forwarded several times and it didn't return what it's supposed to. The solution is, instead of : // SUBPART RECURSION if ($p->parts) { foreach ($p->parts as $partno0=>$p2) getpart($mbox,$mid,$p2,$partno.'.'.($partno0+1)); // 1.2, 1.2.1, etc. } it should be // SUBPART RECURSION if ($p->parts[0]->parts) { foreach ($p->parts[0]->parts as $partno0=>$p2) getpart($mbox,$mid,$p2,$partno.'.'.($partno0+1)); // 1.2, 1.2.1, etc. } Cheers and thanks again for your contribution. ---- Server IP: 69.147.83.197 Probable Submitter: 194.88.249.135 ---- Manual Page -- http://www.php.net/manual/en/function.imap-fetchstructure.php Edit -- https://master.php.net/note/edit/106069 Del: integrated -- https://master.php.net/note/delete/106069/integrated Del: useless -- https://master.php.net/note/delete/106069/useless Del: bad code -- https://master.php.net/note/delete/106069/bad+code Del: spam -- https://master.php.net/note/delete/106069/spam Del: non-english -- https://master.php.net/note/delete/106069/non-english Del: in docs -- https://master.php.net/note/delete/106069/in+docs Del: other reasons-- https://master.php.net/note/delete/106069 Reject -- https://master.php.net/note/reject/106069 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#183701) next »