php-imap
php-imap copied to clipboard
cant save filenames with unallowed chars
Hi there,
i want to save attachments from an email. The filename has unalloed chars (in my case is had a / in fillename). When i try to save this attachments i get a PHP error. in the function "save" under src/Attachment.php you use file_put_contents without checking filename for unallowed chars.
Under wimdows a / in filename is also not allowed. When i try to save attachments with a / in filename, then windows repaces it with _
I think its the best way to replace unallowed chars in filenames with _
thank you!
best regards