As you know, files are stored in binary, but we need to add it as HTML, so as text otherwise, your email client won’t be able to parse it. HTML also enables you to send the files as base64. But, again, it makes sense because we’re sending the file as an attachment, so there’s no reference between the attached image and the one I’m sending. I know what HTML I want to generate: Įven with it attached, the image was not displayed. So the next step was to generate the HTML that will display the image. Unfortunately, it didn’t work since we want the image to be displayed in the email and not attached to the email.Įmails are sent, most of the time, as an HTML file. First, I tried to attach the image to the email. This is the part that many struggles with (myself included) while trying to embed an image. Now that we have the file let’s generate the email. You may want to set up a sub folder in your inbox to store UTS emails that you do not want to delete.So far, so good.
0 Comments
Leave a Reply. |