Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for original base64 images #60

Open
baaskoen opened this issue Aug 15, 2024 · 1 comment
Open

Support for original base64 images #60

baaskoen opened this issue Aug 15, 2024 · 1 comment

Comments

@baaskoen
Copy link

baaskoen commented Aug 15, 2024

Thanks again for this great library!

I would like to propose a new addition for the attachment method.

Issue

If you send an e-mail which which contains an image in its body, it will go through the different checks as seen here:

However, if the original image was already a base64 encoded src, it will not be converted to an embedded image, resulting into clients like Gmail not rendering the image.

Proposal

Add a check for when the image src starts with data:*;base64. When this is the case, embed the image anyway.

@baaskoen
Copy link
Author

I added a MR in a fork which works for me personally. Not tested properly though:

https://github.com/eduardokum/laravel-mail-auto-embed/pull/61/files

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant