WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

episode idea: handling multipart mails (html+text)  #94

@chmike

Description

@chmike

I can’t find a tutorial to create multipart mails with a text part and an utf-8 base64 encoded html part by using the standard library. The best I could find is this but it doesn’t seam to produce a valid mime encoding. An example using templates would be great.

My use case is the following. My Go program is doing a batch processing (e.g. backup, data integrity check, ...) and sends a report by mail. I have a python code that run every night and produce a text only report. When the report is long, it’s hard to locate the problems. I would now like to write the code in Go (because I can), and I’m stuck at generating a multipart mail with problems shown in red in the html part.

Another use case could be to send a multipart mail containing markdown text and its html encoding. The user would provide the markdown text.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions