Zig
Zig
Create Email with Embedded Link
Creating an email with an embedded link (HTML hyperlink).Chilkat Zig Downloads
const std = @import("std");
const chilkat = @import("chilkat");
pub fn main(init: std.process.Init) !void {
const alloc = init.arena.allocator();
const email = try chilkat.Email.init();
defer email.deinit();
// To create an email with an embedded link, use HTML:
const html = "<html><body><p>Click here for more information: <a href=\"http://www.chilkatsoft.com/\">Chilkat Software</a></body></html>";
email.setHtmlBody(html);
// Continue building the email by adding the subject, recipients, etc...
const mime = try email.getMime(alloc);
std.debug.print("{s}\n", .{mime});
}