mailer

package
v0.0.0-...-82acf53 Latest Latest
Warning

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

Go to latest
Published: Nov 16, 2022 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Mailer

type Mailer struct {
	Host     string
	Port     string
	Username string
	Password string
	From     string
	To       []string
	Data     map[string]interface{}
}

Mailer struct

func New

func New(host, port, username, password, from string, to []string, data map[string]interface{}) *Mailer

New returns a pointer to the instance of Mailer

func (*Mailer) Mail

func (m *Mailer) Mail(subject string, body string) error

Mail takes the subject and body and sends the mail

subject: Subject template of the mail body: Body template of the mail

Jump to

Keyboard shortcuts

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