upload

package
v0.0.0-...-4caec29 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckImage

func CheckImage(src string) error

检查文件目录权限,没有则创建

func CheckImageExt

func CheckImageExt(fileName string) bool

检查图片扩展名

func CheckImageSize

func CheckImageSize(f multipart.File) bool

检查图片大小

func GetImageFullPath

func GetImageFullPath() string

获取图片用于保存的完整路径

func GetImageFullURL

func GetImageFullURL(name string) string

获取图片完整的URL

func GetImageName

func GetImageName(name string) string

获取图片名称,将文件名部分转为MD5,后缀不变

func GetImagePath

func GetImagePath() string

获取图片用于保存的相对路径

Types

This section is empty.

Jump to

Keyboard shortcuts

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