feat:完善项目信息

This commit is contained in:
henry
2022-01-13 17:48:41 +08:00
parent 4637a5fb4b
commit 27cb063a6c
11 changed files with 85 additions and 79 deletions

View File

@ -14,8 +14,9 @@ func ValidateEmail(email string) bool {
return reg.MatchString(email)
}
func ValidateUrl(url string) {
//reg := regexp.MustCompile("^([hH][tT]{2}[pP]:|||[hH][tT]{2}[pP][sS]:|www\.)(([A-Za-z0-9-~]+)\.)+([A-Za-z0-9-~\/])+$")
func ValidateUrl(obj string) bool {
reg := regexp.MustCompile("^(https?|ftp|file)://[-A-Za-z0-9+&@#/%?=~_|!:,.;]+[-A-Za-z0-9+&@#/%=~_|]")
return reg.MatchString(obj)
}
func ValidateIDCard(obj string) bool {