Skip to main content

One post tagged with "email"

View All Tags

· One min read
package main

import (
"github.com/scott-x/email"
"github.com/scott-x/randomCode"
)

func main() {
subject := "Slimx News"
body := `【温馨提示】:有人正在尝试访问你的博客, 验证码为: `
code, _ := randomCode.Random(6)
body += code
//send email
email.SendEmail(subject, body)
}