Closed AlexBevilacqua closed 6 years ago
Althhough this is correct and will be fixed, I believe it shouldn't cause issues
Today I had problems while saving attachments from gmail. The filename is setting empty so I have tested the solution proposed by @AlexBevilacqua,
if (strtolower($param->attribute) === 'name')
And it works perfectly but with the current code fails.
This is the error msg I received:
Warning: file_put_contents(C:\...\...\...\...\attachment-dir\...\...\ <----- (here must be the name of file)): failed to open stream: No such file or directory in C:\...\....\...\...\...\vendor\ssilence\php-imap-client\ImapClient\ImapClient.php on line 690.
By this way i can't save attachments of gmail, at least from my gmail account.
Please, could you check this?
I'm using windows and XAMPP.
It's posible to fix this issue?
Thanks in advance.
This will be fixed
Hello Dear,
I have a issue when i'm trying to get my mails its showing error mail-action.txt
Error is:
`INBOX
Notice: Trying to get property of non-object in
C:\xampp\htdocs\ats\classes\phpmail\ImapClient\IncomingMessage.php on line 364
Fatal error: Uncaught Error: Cannot access empty property in
C:\xampp\htdocs\ats\classes\phpmail\ImapClient\IncomingMessage.php:366 Stack trace: #0
C:\xampp\htdocs\ats\classes\phpmail\ImapClient\IncomingMessage.php(178):
SSilence\ImapClient\IncomingMessage->getBody() #1
C:\xampp\htdocs\ats\classes\phpmail\ImapClient\IncomingMessage.php(159):
SSilence\ImapClient\IncomingMessage->init() #2
C:\xampp\htdocs\ats\classes\phpmail\ImapClient\ImapClient.php(644):
SSilence\ImapClient\IncomingMessage->__construct(Resource id #18, 164, 'decode') #3
C:\xampp\htdocs\ats\classes\phpmail\ImapClient\ImapClient.php(567):
SSilence\ImapClient\ImapClient->getMessage(164) #4 C:\xampp\htdocs\ats\mail\mail-action.php(55): SSilence\ImapClient\ImapClient->getMessages() #5
C:\xampp\htdocs\ats\mail\inbox.php(4): include('C:\\xampp\\htdocs...') #6 {main} thrown in
C:\xampp\htdocs\ats\classes\phpmail\ImapClient\IncomingMessage.php on line 366
Notice: Unknown: Invalid quoted-printable sequence: =>. > (errflg=3) in Unknown on line 0`
// Ontopic I have added a commit. Please test your code and let me know // Offtopic @decadence Please use the create issue feature on github
Just ran
composer update
and looked at the canges, so I noticedin file ImapClient/IncomingMessageAttachment.php
https://github.com/SSilence/php-imap-client/blob/1c7514b57cabf5816bb6f75bb560728989575dfd/ImapClient/IncomingMessageAttachment.php#L66
and
https://github.com/SSilence/php-imap-client/blob/1c7514b57cabf5816bb6f75bb560728989575dfd/ImapClient/IncomingMessageAttachment.php#L73
doesn't seems right (closing braket of strtolower), should be
isn't it? Thanks