Comments (7)
I'll take a peek. Thanks.
from php-imap.
hi, to fix the attachments simple change the word attachments to caps lock, like:
From this: disposition == 'attachment'
To this: disposition == 'ATTACHMENT'
But them i found other problem if there is more there one attachment it shows the attachments but gives this error:
Notice: Undefined property: stdClass::$disposition in C:\wamp\www\php-imap-master\classes\imap.class.php on line 187
I fix it doing this:
if($i->ifdisposition == 'ATTACHMENT'){
}
else{
if($i->disposition == 'ATTACHMENT'){
$part = $x+1;
$array['attachments'][] = array('type'=>$i->subtype,'bytes'=>$i->bytes,'name'=>$i->parameters[0]->value,'part'=>$part,'msgno'=>$messageNumber);
}
}
I just wrapped the if inside other if verifying if the 'ifdisposition' is equal to ATTACHMENT, it will never be equal so it will do the else, and don't show the error.
PS: all this is inside the public function returnEmailMessageArr()
i found another error, the script don't show the body of the email, the way I found to put it working was in the index.php, change the base64_decode($email['html']) to quoted_printable_decode($email['html']).
from php-imap.
the message don't work properly in the other folders beside INBOX because you are doing the message number like this:
Array
(
[0] => 1
[1] => 2
[2] => 3
[3] => 4
[4] => 5
[5] => 6
[6] => 7
[7] => 8
[8] => 9
[9] => 10
[10] => 11
[11] => 12
[12] => 13
[13] => 14
[14] => 15
[15] => 16
[16] => 17
[17] => 18
)
when you should be getting the message original number ( the one that imap_search( you stream, 'ALL', SE_UID) returns ) which in my case would be:
Array
(
[0] => 1
[1] => 2
[2] => 3
[3] => 4
[4] => 5
[5] => 6
[6] => 10
[7] => 12
[8] => 14
[9] => 19
[10] => 20
[11] => 21
[12] => 22
[13] => 23
[14] => 24
[15] => 30
[16] => 34
[17] => 35
)
from php-imap.
You should fork and commit your fixes.
from php-imap.
I have already done that, the only thing that i can´t fix is the messages numbers, mainly because I can't find a way without rewrite almost all of you code.
So I would be very glad, if you could do that.
thanks
from php-imap.
okay leeme see what i can do.
from php-imap.
Hi, any news?
from php-imap.
Related Issues (2)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from php-imap.