note 116428 added to function.imap-fetchbody
| From: | mike at lathyrus dot net | Date: | Thu, 01 Jan 2015 16:37:43 +0000 |
| Subject: | note 116428 added to function.imap-fetchbody | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-201291@lists.php.net to get a copy of this message | ||
I spent hours religously thinking that
imap_fetchbody($mbox,$email_number,1.2)
would fetch the html body, and in many cases this did not work. It turns out that simple message
can have a simple [parts] stucture so this became true:
imap_fetchbody($mbox,$email_number,1) - PLAIN
imap_fetchbody($inbox,$email_number,2) - HTML
Check for empty string before using the latter.
----
Server IP: 72.52.91.14
Probable Submitter: 80.176.117.33
----
Manual Page -- http://php.net/manual/en/function.imap-fetchbody.php
Edit -- https://master.php.net/note/edit/116428
Del: integrated -- https://master.php.net/note/delete/116428/integrated
Del: useless -- https://master.php.net/note/delete/116428/useless
Del: bad code -- https://master.php.net/note/delete/116428/bad+code
Del: spam -- https://master.php.net/note/delete/116428/spam
Del: non-english -- https://master.php.net/note/delete/116428/non-english
Del: in docs -- https://master.php.net/note/delete/116428/in+docs
Del: other reasons-- https://master.php.net/note/delete/116428
Reject -- https://master.php.net/note/reject/116428
Search -- https://master.php.net/manage/user-notes.php