maillib

package module
v0.0.0-...-82cdbcf Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 17, 2023 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Attach

func Attach(filelist string)

Attach ads list of files (comma seperated full path)

func Bcc

func Bcc(bcclist string)

Bcc sets the list of comma seperated Bcc'ed recipents

func Cc

func Cc(cclist string)

Cc sets the list of comma seperated CC'ed recipents

func SendMail

func SendMail(from string, to string, subject string, text string) (err error)

SendMail send a mail with the given content

func SetConfig

func SetConfig(server string, port int, username string, password string, tls bool)

SetConfig set Mail server parameter

func SetContentType

func SetContentType(contentType mail.ContentType)

SetContentType allows to modify the Content type of the mail

func SetMaxSize

func SetMaxSize(maxsize int64)

SetMaxSize limits the size of attached files, 0 to disable

Types

type MailConfigType

type MailConfigType struct {
	Server      string
	Port        int
	Username    string
	Password    string
	Tls         bool
	Maxsize     int64
	ContentType mail.ContentType
}

func GetConfig

func GetConfig() MailConfigType

GetConfig returns current Mail conf

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL