utils

package
v0.0.0-...-bd304fc Latest Latest
Warning

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

Go to latest
Published: Jun 27, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrorEmailFormat    = errors.New("Email format error")
	ErrorMobileFormat   = errors.New("Mobile format error")
	ErrorPwdFormat      = errors.New("Password format error")
	ErrorUsernameformat = errors.New("Username format error")
)

error set

Functions

func CheckTheValidityOfChinaMobile

func CheckTheValidityOfChinaMobile(mobile string) (err error)

CheckTheValidityOfChinaMobile -

func CheckTheValidityOfEmail

func CheckTheValidityOfEmail(email string) (err error)

CheckTheValidityOfEmail -

func CheckTheValidityOfPassword

func CheckTheValidityOfPassword(password string) (err error)

CheckTheValidityOfPassword -

func CheckTheValidityOfUsername

func CheckTheValidityOfUsername(username string) (err error)

CheckTheValidityOfUsername -

func GetIDWithCookie

func GetIDWithCookie(w http.ResponseWriter, r *http.Request) (ID int)

GetIDWithCookie -

func HashPwdCompare

func HashPwdCompare(hashedPwd []byte, password string) bool

HashPwdCompare -

func HashPwdGenerate

func HashPwdGenerate(password string) (hashPwd string, err error)

HashPwdGenerate -

func SendMail

func SendMail(to string) (err error)

SendMail -

Types

This section is empty.

Jump to

Keyboard shortcuts

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